2016-08-23 12:44:38 +00:00
|
|
|
# rsyslog configuration file
|
|
|
|
|
|
|
|
# For more information see /usr/share/doc/rsyslog-*/rsyslog_conf.html
|
|
|
|
# If you experience problems, see http://www.rsyslog.com/doc/troubleshoot.html
|
|
|
|
|
2010-10-19 15:35:50 +00:00
|
|
|
#### MODULES ####
|
2016-08-23 12:44:38 +00:00
|
|
|
|
|
|
|
# The imjournal module bellow is now used as a message source instead of imuxsock.
|
|
|
|
$ModLoad imuxsock # provides support for local system logging (e.g. via logger command)
|
2011-04-27 13:03:10 +00:00
|
|
|
$SystemLogRateLimitInterval 0 # disables message dropping, we need all of them
|
2016-08-23 12:44:38 +00:00
|
|
|
$ModLoad imjournal # provides access to the systemd journal
|
2017-02-14 12:38:39 +00:00
|
|
|
#$ModLoad imklog # reads kernel messages (the same are read from journald)
|
2016-08-23 12:44:38 +00:00
|
|
|
#$ModLoad immark # provides --MARK-- message capability
|
|
|
|
|
|
|
|
# Provides UDP syslog reception
|
|
|
|
#$ModLoad imudp
|
|
|
|
#$UDPServerRun 514
|
|
|
|
|
|
|
|
# Provides TCP syslog reception
|
|
|
|
#$ModLoad imtcp
|
|
|
|
#$InputTCPServerRun 514
|
2010-10-19 15:35:50 +00:00
|
|
|
|
|
|
|
$ModLoad imfile
|
|
|
|
$InputFileName /tmp/X.log
|
|
|
|
$InputFileTag xserver:
|
|
|
|
$InputFileStateFile xserver-statefile
|
|
|
|
$InputFileFacility local1
|
|
|
|
$InputRunFileMonitor
|
|
|
|
$InputFileName /tmp/anaconda-tb-all.log
|
|
|
|
$InputFileTag anaconda-tb:
|
|
|
|
$InputFileStateFile anaconda-tb-statefile
|
|
|
|
$InputFileFacility local1
|
|
|
|
$InputRunFileMonitor
|
|
|
|
|
2016-08-23 12:44:38 +00:00
|
|
|
|
2010-10-19 15:35:50 +00:00
|
|
|
#### GLOBAL DIRECTIVES ####
|
2016-08-23 12:44:38 +00:00
|
|
|
|
|
|
|
# Where to place auxiliary files
|
|
|
|
#$WorkDirectory /var/lib/rsyslog
|
|
|
|
|
2010-10-19 15:35:50 +00:00
|
|
|
# Use default timestamp format
|
|
|
|
$ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat
|
|
|
|
|
2016-08-23 12:44:38 +00:00
|
|
|
# File syncing capability is disabled by default. This feature is usually not required,
|
|
|
|
# not useful and an extreme performance hit
|
|
|
|
#$ActionFileEnableSync on
|
|
|
|
|
|
|
|
# Include all config files in /etc/rsyslog.d/
|
|
|
|
$IncludeConfig /etc/rsyslog.d/*.conf
|
|
|
|
|
|
|
|
# Turn off message reception via local log socket;
|
|
|
|
# local messages are retrieved through imjournal now.
|
|
|
|
$OmitLocalLogging on
|
|
|
|
|
|
|
|
# File to store the position in the journal
|
|
|
|
$IMJournalStateFile imjournal.state
|
|
|
|
|
2010-10-19 15:35:50 +00:00
|
|
|
#### TEMPLATES ####
|
|
|
|
|
|
|
|
$template anaconda_tty4, "%syslogseverity-text:::uppercase% %programname%:%msg%\n"
|
|
|
|
$template anaconda_syslog, "%timestamp:8:$:date-rfc3164%,%timestamp:1:3:date-subseconds% %syslogseverity-text:::uppercase% %programname%:%msg%\n"
|
2011-10-13 14:31:45 +00:00
|
|
|
$template virtio_ForwardFormat, "<%PRI%>%TIMESTAMP:::date-rfc3339% localhost %syslogtag:1:32%%msg:::sp-if-no-1st-sp%%msg%\n"
|
2010-10-19 15:35:50 +00:00
|
|
|
|
|
|
|
#### RULES ####
|
2016-08-23 12:44:38 +00:00
|
|
|
|
2010-10-19 15:35:50 +00:00
|
|
|
# log everything except anaconda-specific records from local1 (those are stored
|
|
|
|
# directly into files via python logging)
|
2016-08-23 12:44:38 +00:00
|
|
|
|
2016-08-23 12:50:59 +00:00
|
|
|
# discard messages from dracut regenerating initrd
|
|
|
|
:programname,isequal,"dracut" ~
|
|
|
|
|
2010-10-19 15:35:50 +00:00
|
|
|
*.*;\
|
|
|
|
authpriv.none;\
|
|
|
|
local1.none /tmp/syslog;anaconda_syslog
|
|
|
|
& /dev/tty4;anaconda_tty4
|
|
|
|
|
2016-08-23 12:44:38 +00:00
|
|
|
|
2010-10-19 15:35:50 +00:00
|
|
|
# ### begin forwarding rule ###
|
|
|
|
# The statement between the begin ... end define a SINGLE forwarding
|
|
|
|
# rule. They belong together, do NOT split them. If you create multiple
|
|
|
|
# forwarding rules, duplicate the whole block!
|
2016-08-23 12:44:38 +00:00
|
|
|
# Remote Logging (we use TCP for reliable delivery)
|
2010-10-19 15:35:50 +00:00
|
|
|
#
|
|
|
|
# An on-disk queue is created for this action. If the remote host is
|
|
|
|
# down, messages are spooled to disk and sent when it is up again.
|
2016-08-23 12:44:38 +00:00
|
|
|
#$ActionQueueFileName fwdRule1 # unique name prefix for spool files
|
2010-10-19 15:35:50 +00:00
|
|
|
$ActionQueueMaxDiskSpace 1m # space limit (use as much as possible)
|
|
|
|
$ActionQueueSaveOnShutdown off # do not save messages to disk on shutdown
|
2016-08-23 12:44:38 +00:00
|
|
|
#$ActionQueueType LinkedList # run asynchronously
|
|
|
|
#$ActionResumeRetryCount -1 # infinite retries if host is down
|
2010-10-19 15:35:50 +00:00
|
|
|
# remote host is: name/ip:port, e.g. 192.168.0.1:514, port optional
|
2016-08-23 12:44:38 +00:00
|
|
|
#*.* @@remote-host:514
|
2010-10-19 15:35:50 +00:00
|
|
|
# ### end of the forwarding rule ###
|