summaryrefslogtreecommitdiff
path: root/docs/syslog.conf.txt (plain)
blob: 6d9c4a173a670540b0bf95ff227d71021795c84c
1If syslogd applet compiled with FEATURE_SYSLOGD_CFG=y, then it supports restricted syslog.conf.
2The config resembles rsyslog.conf in RULES part:
3
4LINE = DELIM [RULE | COMMENT]
5COMMENT = #.*
6DELIM = SPACE TAB
7RULE = SELECTOR [;SELECTOR]* DELIM* ACTION DELIM*
8SELECTOR = FACILITY [,FACILITY]* .[[!]=] PRIORITY
9FACILITY = * | kern | user ... (see syslog.h)
10PRIORITY = * | emerg | alert ... (see syslog.h)
11ACTION = FILE
12
13"mark" facility is NOT supported.
14"none" priority is supported.
15In FACILITY and PRIORITY "*" stands for "any".
16FILE is a regular file or tty device.
17
18Here is an example:
19
20#syslog.conf
21kern,user.* /var/log/messages #all messages of kern and user facilities
22kern.!err /var/log/critical #all messages of kern facility with priorities lower than err (warn, notice ...)
23*.*;auth,authpriv.none /var/log/noauth #all messages except ones with auth and authpriv facilities
24kern,user.*;kern.!=notice;*.err;syslog.none /var/log/OMG #some whicked rule just as an example =)
25*.* /dev/null #this prevents from logging to default log file (-O FILE or /var/log/messages)
26
27Even in the case of match with some rule another rules will be tried too.
28If there was no match with any of the rules, logging to default log file or shared memory will be performed.
29