The
syslog
option causes Samba log messages to be sent to the Unix system logger. The type of log information to be sent is specified as the parameter for this argument. Like the
log
level
option, it can be a number from 0 to 10. Logging information with a level less than the number specified will be sent to the system logger. However, debug logs equal to or above the
syslog
level, but less than log level, will still be sent to the standard Samba log files. To get around this, use the
syslog
only
option. For example:
[global]
log level = 3
syslog = 1
With this, all logging information with a level of 0 would be sent to the standard Samba logs and the system logger, while information with levels 1, 2, and 3 would be sent only to the standard Samba logs. Levels above 3 are not logged at all. Note that all messages sent to the system logger are mapped to a priority level that the
syslog process understands, as shown in
Table 4.8. The default level is 1.
If you wish to use
syslog, you will have to run
configure
--with-syslog
when compiling Samba, and you will need to configure your
/etc/syslog.conf to suit. (See the section
Section 4.8.1, Using syslog," earlier in this chapter.)