|ssize||sets the maximum file size of current when svlogd should rotate the current log file to size bytes. Default is 1000000. If size is zero, svlogd doesnt rotate log files. You should set size to at least (2 * len).|
|nnum||sets the number of old log files svlogd should maintain to num. If svlogd sees more that num old log files in log after log file rotation, it deletes the oldest one. Default is 10. If num is zero, svlogd doesnt remove old log files.|
|Nmin||sets the minimum number of old log files svlogd should maintain to min. min must be less than num. If min is set, and svlogd cannot write to current because the filesystem is full, and it sees more than min old log files, it deletes the oldest one.|
|sets the maximum age of the current log file when svlogd should rotate the current log file to timeout seconds. If current is timeout seconds old, and is not empty, svlogd forces log file rotation.|
|tells svlogd to feed each recent log file through processor (see above) on log file rotation. By default log files are not processed.|
|tells svlogd to transmit the first len characters of selected log messages to the IP address a.b.c.d, port number port. If port isnt set, the default port for syslog is used (514). len can be set through the -l option, see below. If svlogd has trouble sending udp packets, it writes error messages to the log directory. Attention: logging through udp is unreliable, and should be used in private networks only.|
|is the same as the u line above, but the log messages are no longer written to the log directory, but transmitted through udp only. Error messages from svlogd concerning sending udp packages still go to the log directory.|
|tells svlogd to prefix each line to be written to the log directory, to standard error, or through UDP, with prefix.|
|If a line starts with a -, +, e, or E, svlogd matches the first len characters of each log message against pattern and acts accordingly:|
|the log message is deselected.|
|the log message is selected.|
|the log message is selected to be printed to standard error.|
|the log message is deselected to be printed to standard error.|
svlogd matches a log message against the string pattern as follows:
pattern is applied to the log message one character by one, starting with the first. A character not a star (*) and not a plus (+) matches itself. A plus matches the next character in pattern in the log message one or more times. A star before the end of pattern matches any string in the log message that does not include the next character in pattern. A star at the end of pattern matches any string.
Timestamps optionally added by svlogd are not considered part of the log message.
An svlogd pattern is not a regular expression. For example consider a log message like this
2005-12-18_09:13:50.97618 tcpsvd: info: pid 1977 from 10.4.1.14
The following pattern doesnt match
because the first star matches up to the first p in tcpsvd, and then the match fails because i is not s. To match this log message, you can use a pattern like this instead
-*: *: pid *
-t timestamp. Prefix each selected line with a precise timestamp (see the daemontools tai64n program) when writing to log or to standard error. -tt timestamp. Prefix each selected line with a human readable, sortable UTC timestamp of the form YYYY-MM-DD_HH:MM:SS.xxxxx when writing to log or to standard error. -ttt timestamp. Prefix each selected line with a human readable, sortable UTC timestamp of the form YYYY-MM-DDTHH:MM:SS.xxxxx when writing to log or to standard error. -r c replace. c must be a single character. Replace non-printable characters in log messages with c. Characters are replaced before pattern matching is applied. -R xyz replace charset. Additionally to non-printable characters, replace all characters found in xyz with c (default _). -l len line length. Pattern matching applies to the first len characters of a log message only. Default is 1000. -b buflen buffer size. Set the size of the buffer svlogd uses when reading from standard input and writing to logs to buflen. Default is 1024. buflen must be greater than len. For svlogd instances that process a lot of data in short time, the buffer size should be increased to improve performance. -v verbose. Print verbose messages to standard error.
If svlogd is sent a HUP signal, it closes and reopens all logs, and updates their configuration according to log/config. If svlogd has trouble opening a log directory, it prints a warning, and discards this log directory. If svlogd is unable to open all log directories given at the command line, it exits with an error.
If svlogd is sent a TERM signal, or if it sees end-of-file on standard input, it stops reading standard input, processes the data in the buffer, waits for all processor subprocesses to finish if any, and exits 0 as soon as possible.
If svlogd is sent an ALRM signal, it forces log file rotation for all logs with a non empty current log file.
Gerrit Pape <email@example.com>