rsylog: Accept remote log messages over TCP.
[matthijs/servers/tika.git] / etc / rsyslog.conf
1 #  /etc/rsyslog.conf    Configuration file for rsyslog.
2 #
3 #                       For more information see
4 #                       /usr/share/doc/rsyslog-doc/html/rsyslog_conf.html
5
6
7 #################
8 #### MODULES ####
9 #################
10
11 $ModLoad imuxsock # provides support for local system logging
12 $ModLoad immark   # provides --MARK-- message capability
13 $MarkMessagePeriod  900 # mark messages appear every 15 Minutes
14
15 $ModLoad imtcp
16 $InputTCPServerRun 514 # Accept TCP connections on the default syslog port
17
18 ###########################
19 #### GLOBAL DIRECTIVES ####
20 ###########################
21
22 #
23 # Use traditional timestamp format.
24 # To enable high precision timestamps, comment out the following line.
25 #
26 $ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat
27
28 #
29 # Set the default permissions for all log files.
30 #
31 $FileOwner root
32 $FileGroup adm
33 $FileCreateMode 0640
34 $DirCreateMode 0755
35 $Umask 0022
36
37 #
38 # Include all config files in /etc/rsyslog.d/
39 #
40 $IncludeConfig /etc/rsyslog.d/*.conf
41
42 # Store any queues here. This directory is not created automatically, so it
43 # must already exist!
44 $WorkDirectory /var/spool/rsyslog
45
46 # Use a (disk-assisted) main queue
47 # Use a linked list for queueing
48 $MainMsgQueueType LinkedList
49 # Name to use for the queue file
50 $MainMsgQueueFileName main
51 # save in-memory data if rsyslog shuts down
52 $MainMsgQueueSaveOnShutdown on
53
54 #######################
55 #### Local logging ####
56 #######################
57
58 # Discard all log entries not locally generated (note that the ~ here is the
59 # "discard" action, preventing the rules below from bein ran on these messages.
60 if $fromhost-ip != '127.0.0.1' then ~
61
62
63 # Log each facility into its own log
64 auth,authpriv.*                 /var/log/rsyslog/auth.log
65 cron.*                          -/var/log/rsyslog/user.log
66 daemon.*                        -/var/log/rsyslog/daemon.log
67 kern.*                          -/var/log/rsyslog/kern.log
68 lpr.*                           -/var/log/rsyslog/lpr.log
69 mail.*                          -/var/log/rsyslog/mail.log
70 user.*                          -/var/log/rsyslog/user.log
71 local0,local1,local2,\
72         local3,local4,local5,\
73         local6,local7.*         -/var/log/rsyslog/local.log
74
75 # Omitted facilities: syslog, news, uucp, ftp
76
77 # All logs end up in syslog as weel as the corresponding facility log above
78 # (except for auth, mail which only end up in the facility log for privacy
79 # reasons and debug which only ends up in the debug log below to prevent
80 # flooding).
81 *.*;\
82         *.!=debug;\
83         auth,authpriv.none;\
84         mail.none               -/var/log/rsyslog/syslog
85
86 # Debug entries end up in debug.log as well as the corresponding facility log
87 # above (except for auth and mail, which only end up in the facility logs for
88 # privacy reasons).
89 *.=debug;\
90         auth,authpriv.none;\
91         news.none;mail.none     -/var/log/rsyslog/debug.log
92 #
93 # Emergencies are sent to everybody logged in.
94 #
95 *.emerg                         *