Further documentation improvements 07/191407/3
authorMichal Bloch <m.bloch@samsung.com>
Tue, 16 Oct 2018 12:49:05 +0000 (14:49 +0200)
committerHyotaek Shim <hyotaek.shim@samsung.com>
Wed, 17 Oct 2018 00:52:07 +0000 (00:52 +0000)
 * fix some mistakes in the previous documentation commit
 * in particular, make the txt file actually end up in the doc rpm
 * extend config entry documentation
 * remove unused entries

Change-Id: I6f423ee42f5fc26059ee738909208719e4dd6753
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
configs/20-pipe.conf
configs/25-logger.conf
configs/dlog.conf
documentation/dlog_ctl.txt [moved from doc/dlog_ctl.txt with 94% similarity]

index 14337df..04a1905 100644 (file)
@@ -32,7 +32,7 @@ radio_size=1048576
 # Daemon's sorting method, ideally same as whichever util uses.
 # The 4 possible values are "{sent,recv}_{mono,real}".
 # Defaults to sent_mono
-#sort_by=sent_mono;
+#sort_by=sent_mono
 
 # Passive logging to file done by the daemon.
 #
index 38a2abe..54925f0 100644 (file)
@@ -1,27 +1,31 @@
 backend=logger
 
+# Paths to the appropriate devices for the four "classic" buffers
+# Multiple devices can be specified, delimited by ':'
+# This allows to create a backup in case a buffer is missing
+# IF the value has a colon AT THE END, the buffer is OPTIONAL
+# ELSE the buffer is MANDATORY and will crash if all devices are missing
 main=/dev/log_main
 apps=/dev/log_apps:/dev/log_events:/dev/log_main
 system=/dev/log_system:/dev/log_main
 radio=/dev/log_radio:/dev/log_main
 
-main_size=1048576
-apps_size=1048576
-system_size=1048576
-radio_size=1048576
-
+# Passive logging, see the main `dlog.conf` file for details
 # NOTE: Do not change the following key names!  When different backend
 #       is used (eg. logger, via 25-logger.conf) these will be overriden.
 dlog_logger_conf_kmsg=dlogutil -b kmsg -r 1024 -n 1 -f /var/log/dlog/kernel -v rwtime
-util_sorting_buffer_size=8192
 
+# Daemon throttling
 # controls how many logs the daemon will try to read at once
 # from an Android Logger device, affecting how a busy buffer
 # will influence others; use with caution
 #  - a higher value means it is more likely to starve them
 #  - a lower one means it will lose logs itself
-# this is the default for all buffers:
-#logger_dev_throttling=100
-# but setting a buffer-specific value is also possible:
+
+# the default for all buffers (if missing, 100 is used)
+logger_dev_throttling=100
+
+# setting a buffer-specific value is also possible,
+# taking precedence over the default
 #logger_dev_throttling_radio=1000
 #logger_dev_throttling_main=80
index d036953..43f8330 100644 (file)
@@ -1,6 +1,7 @@
 # Lines starting with # are comments and are ignored.
 # Empty lines are also ignored.
 # Every other line is a config value and has to be in key=value format
+# Maximum key length is currently 31 bytes and maximum value length is 255
 
 ##### Settings used by the logging library
 
@@ -15,6 +16,7 @@ enable_system=1
 enable_apps=1
 
 # Debugmode - whether write platform debug log or not
+# If disabled, logs at priority levels DEBUG and below - this means also VERBOSE - are completely dropped
 debugmode=1
 
 # Limiter - whether it's enabled and the rules (check the documentation for how to create rules).
@@ -27,6 +29,7 @@ limiter_apply_to_all_buffers=0
 # dynamic_config_path=/run/dlog/filters.d/
 
 ##### Settings used by the logging daemon
+# See also 20-pipe.conf for more info
 
 kmsg=/dev/null
 syslog=/dev/null
@@ -59,10 +62,21 @@ syslog_size=1048576
 ##### Settings used by dlogutil
 
 # Sorting time window (in milliseconds). Proportional to sorting quality, but also delay.
+# Defaults to 1000
 util_sorting_time_window=1000
 
-# If sorting buffer is full, all logs are printed regardless of current sorting status.
-#util_sorting_buffer_size=1048576
+# Sorting buffer size (in entries). Larger values heavily increase performance demands but also
+# lower the chance a log gets printed out of requested order. The whole sorting container gets
+# allocated at once on start so avoid large values. This value gets overridden by `-u`, can be
+# increased by `-t` if it is larger, and is completely ignored when the requested sorting order
+# agrees with what the source provides.
+#util_sorting_buffer_size=131072
+
+# Passive logging.
+# Works AS IF a dlogutil instance was active and writing to a file (not a real instance!)
+# The key has to be of the format `dlog_logger_conf_%s`, where %s is an arbitrary idenfitier.
+# The value has to start with "dlogutil" and must contain the `-f` option, which specifies the path.
+# Otherwise accepts same parameters (including filters) as the regular executable dlogutil.
 
 # NOTE: Do not change the following key names!
 #       Additional configuration files (in dlog.conf.d) might want to override these.
similarity index 94%
rename from doc/dlog_ctl.txt
rename to documentation/dlog_ctl.txt
index 2a5e7ce..0a46c36 100644 (file)
@@ -6,7 +6,7 @@ to which all users of the library have read access; put path to this directory
 to the `dynamic_config_path` config entry. For example, if that directory is
 the default (i.e. `/run/dlog/filters.d`):
 
- $ echo "dynamic_config_path=/tmp/foo" >> /opt/etc/dlog.conf
+ $ echo "dynamic_config_path=/run/dlog/filters.d" >> /opt/etc/dlog.conf
 
 Now dynamic control can be exerted. There are two features configurable at
 runtime, the first is an extension of the filtering limiter. Of course to
@@ -30,8 +30,8 @@ And some example output:
  > * system: DISABLED
  > * apps: ENABLED
 
-In this case we can see that there's a rule to block the FOO tag and to limit
-W priority logs; see the filter documentation on what the specific values mean.
+In this case we can see that there's a rule to block the FOO tag and no limit
+upon other logs; see the filter documentation on what the specific values mean.
 Some buffers have also been disabled, more on that later.
 
 Let's say we want to block logs by default; this involves setting the global
@@ -74,7 +74,7 @@ To remove a dynamic rule, use `--set` without a parameter:
  > [shadowed] Unlimited for *:* (static)
 
 Earlier we could see that dumping also tells us about buffer status.
-This is an override that prevents logs from being set to a buffer completely.
+This is an override that prevents logs from being sent to a buffer completely.
 To enable or disable a buffer, do:
 
  $ dlogctl --enable -b radio -b system