1 .\" syslog.conf - syslogd(8) configuration file
2 .\" Copyright (c) 1995 Martin Schulze <Martin.Schulze@Linux.DE>
3 .\" Modified for Minix porting by G. Falzoni <gfalzoni@inwind.it>
5 .\" This file is part of the sysklogd package, a kernel and system log daemon.
7 .\" This program is free software; you can redistribute it and/or modify
8 .\" it under the terms of the GNU General Public License as published by
9 .\" the Free Software Foundation; either version 2 of the License, or
10 .\" (at your option) any later version.
12 .\" This program is distributed in the hope that it will be useful,
13 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
14 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 .\" GNU General Public License for more details.
17 .\" You should have received a copy of the GNU General Public License
18 .\" along with this program; if not, write to the Free Software
19 .\" Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
41 .TH SYSLOG.CONF 5 "1 January 1998"
43 syslog.conf \- syslogd(8) configuration file
47 file is the main configuration file for the
49 which logs system messages on *nix systems. This file specifies rules
50 for logging. For special features see the
53 Every rule consists of two fields, a
57 field. These two fields are separated by one or more tabs.
58 The selector field specifies a pattern of facilities and
59 priorities belonging to the specified action.
60 Lines starting with a hash mark (``#'') and empty lines are ignored.
62 The selector field itself again consists of two parts, a
66 separated by a period (``.'').
67 Both parts are case insensitive and can also be specified as decimal
68 numbers, but don't do that, you have been warned. Both facilities and
69 priorities are described in
71 The names mentioned below correspond to the similar
74 .IR /usr/include/syslog.h .
77 is one of the following keywords:
78 .BR auth ", " authpriv ", " cron ", " daemon ", " kern ", " lpr ", "
79 .BR mail ", " mark ", " news ", " security " (same as " auth "), "
80 .BR syslog ", " user ", " uucp " and " local0 " through " local7 .
83 should not be used anymore and
85 is only for internal use and therefore should not be used in
86 applications. Anyway, you may want to specify and redirect these
89 specifies the subsystem that produced the message, i.e. all mail
90 programs log with the mail facility
92 if they log using syslog.
96 is one of the following keywords, in ascending order:
97 .BR debug ", " info ", " notice ", " warning ", " warn " (same as "
98 .BR warning "), " err ", " error " (same as " err "), " crit ", "
99 .BR alert ", " emerg ", " panic " (same as " emerg ).
101 .BR error ", " warn " and " panic
102 are deprecated and should not be used anymore. The
104 defines the severity of the message
106 The behavior of the original BSD syslogd is that all messages of the
107 specified priority and higher are logged according to the given
110 behaves the same, but has some extensions.
112 In addition to the above mentioned names the
114 understands the following extensions:
115 .LB 5 "*" "An asterisk (``*'') before the period stands for all facilities.
116 .LB 5 "none" "The keyword none stands for no priority of the given facility.
118 Multiple selectors may be specified for a single
120 using the semicolon (``;'') separator. Remember that each selector in
123 field is capable to overwrite the preceding ones. Using this
124 behavior you can exclude some priorities from the pattern.
126 The action field of a rule describes the abstract term
127 ``logfile''. A ``logfile'' need not to be a real file, btw. The
129 provides the following actions.
131 Typically messages are logged to real files. The file has to be
132 specified with full pathname, beginning with a slash ``/''.
133 .SS Terminal and Console
134 If the file you specified is a tty, special tty-handling is done, same
138 This release does not implement
139 remote logging, i.e. the ability to send messages to a remote host running
141 To forward messages to another host, prepend the hostname
142 with the at sign (``@'').
144 Usually critical messages are also directed to ``root'' on that
145 machine. You can specify a list of users that shall get the message by
146 simply writing the login. You may specify more than one user by
147 separating them with commas (``,''). If they're logged in they
148 get the message. Don't think a mail would be sent, that might be too
150 .SS Everyone logged on
151 Emergency messages often go to all users currently online to notify
152 them that something strange is happening with the system. To specify
155 use an asterisk (``*'').
157 Here are some example, partially taken from a real existing site and
158 configuration. Hopefully they rub out all questions to the
159 configuration, if not, drop me (Joey) a line.
162 # Store critical stuff in critical
164 *.crit /var/adm/critical
167 This will store all messages with the priority
170 .IR /var/adm/critical .
173 # The tcp wrapper loggs with mail.info, we display
174 # all the connections on tty12
179 This directs all messages that uses
180 .BR mail.info " (in source " LOG_MAIL " | " LOG_INFO )
186 # Log all mail.info and news.info messages to info
188 mail,news.info /var/adm/info
191 This will extract all messages that come either with
192 .BR mail.info " or with " news.info
193 and store them in the file
197 # Emergency messages will be displayed using wall
204 to write all emergency messages to all currently logged in users. This
208 # Messages of the priority alert will be directed
214 This rule directs all messages with a priority of
216 or higher to the terminals of the operator, i.e. of the users ``root''
217 and ``joey'' if they're logged in.
223 This rule would redirect all messages to a remote host called
224 finlandia. This is useful especially in a cluster of machines where
225 all syslog messages will be stored on only one machine.
228 Configuration file for
231 The effects of multiple selectors are sometimes not intuitive. For
232 example ``mail.crit,*.err'' will select ``mail'' facility messages at
233 the level of ``err'' or higher, not at the level of ``crit'' or
243 is taken from BSD sources, Greg Wettstein (greg@wind.rmcc.com)
244 performed the port to Linux, Martin Schulze (joey@linux.de)
245 made some bugfixes and added some new features.