Tomas Heinrich 5014001
# rsyslog configuration file
6a5d467
Tomas Heinrich 84ef2a1
# For more information see /usr/share/doc/rsyslog-*/rsyslog_conf.html
4674d1c
# or latest version online at http://www.rsyslog.com/doc/rsyslog_conf.html 
Tomas Heinrich 84ef2a1
# If you experience problems, see http://www.rsyslog.com/doc/troubleshoot.html
6a5d467
6a5d467
#### MODULES ####
6a5d467
4674d1c
module(load="imuxsock" 	  # provides support for local system logging (e.g. via logger command)
4674d1c
       SysSock.Use="off") # Turn off message reception via local log socket; 
4674d1c
			  # local messages are retrieved through imjournal now.
4674d1c
module(load="imjournal" 	    # provides access to the systemd journal
4674d1c
       StateFile="imjournal.state") # File to store the position in the journal
4674d1c
#module(load="imklog") # reads kernel messages (the same are read from journald)
4674d1c
#module(load"immark") # provides --MARK-- message capability
6a5d467
6a5d467
# Provides UDP syslog reception
4674d1c
# for parameters see http://www.rsyslog.com/doc/imudp.html
4674d1c
#module(load="imudp") # needs to be done just once
4674d1c
#input(type="imudp" port="514")
6a5d467
6a5d467
# Provides TCP syslog reception
4674d1c
# for parameters see http://www.rsyslog.com/doc/imtcp.html
4674d1c
#module(load="imtcp") # needs to be done just once
4674d1c
#input(type="imtcp" port="514")
6a5d467
502ec1b
#### GLOBAL DIRECTIVES ####
502ec1b
Tomas Heinrich d9d32ce
# Where to place auxiliary files
9a9f6af
global(workDirectory="/var/lib/rsyslog")
Tomas Heinrich d9d32ce
502ec1b
# Use default timestamp format
4674d1c
module(load="builtin:omfile" Template="RSYSLOG_TraditionalFileFormat")
502ec1b
Tomas Heinrich 84ef2a1
# Include all config files in /etc/rsyslog.d/
b05cdc6
include(file="/etc/rsyslog.d/*.conf" mode="optional")
Tomas Heinrich 84ef2a1
6a5d467
#### RULES ####
6a5d467
6a5d467
# Log all kernel messages to the console.
6a5d467
# Logging much else clutters up the screen.
6a5d467
#kern.*                                                 /dev/console
6a5d467
6a5d467
# Log anything (except mail) of level info or higher.
6a5d467
# Don't log private authentication messages!
6a5d467
*.info;mail.none;authpriv.none;cron.none                /var/log/messages
6a5d467
6a5d467
# The authpriv file has restricted access.
6a5d467
authpriv.*                                              /var/log/secure
6a5d467
6a5d467
# Log all the mail messages in one place.
6a5d467
mail.*                                                  -/var/log/maillog
6a5d467
6a5d467
6a5d467
# Log cron stuff
6a5d467
cron.*                                                  /var/log/cron
6a5d467
6a5d467
# Everybody gets emergency messages
Tomas Heinrich f631987
*.emerg                                                 :omusrmsg:*
6a5d467
6a5d467
# Save news errors of level crit and higher in a special file.
6a5d467
uucp,news.crit                                          /var/log/spooler
6a5d467
6a5d467
# Save boot messages also to boot.log
6a5d467
local7.*                                                /var/log/boot.log
6a5d467
502ec1b
4674d1c
# ### sample forwarding rule ###
4674d1c
#action(type="omfwd"  
b05cdc6
# # An on-disk queue is created for this action. If the remote host is
b05cdc6
# # down, messages are spooled to disk and sent when it is up again.
4674d1c
#queue.filename="fwdRule1"       # unique name prefix for spool files
4674d1c
#queue.maxdiskspace="1g"         # 1gb space limit (use as much as possible)
4674d1c
#queue.saveonshutdown="on"       # save messages to disk on shutdown
4674d1c
#queue.type="LinkedList"         # run asynchronously
4674d1c
#action.resumeRetryCount="-1"    # infinite retries if host is down
b05cdc6
# # Remote Logging (we use TCP for reliable delivery)
b05cdc6
# # remote_host is: name/ip, e.g. 192.168.0.1, port optional e.g. 10514
4674d1c
#Target="remote_host" Port="XXX" Protocol="tcp")