-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrsyslograd.conf
58 lines (47 loc) · 1.24 KB
/
rsyslograd.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#################
#### MODULES ####
#################
# $ModLoad imudp
$ModLoad imtcp
# provides UDP syslog reception
# $UDPServerRun 1514
# provides TCP syslog reception
$InputTCPServerRun 514
###########################
#### GLOBAL DIRECTIVES ####
###########################
#
# Use traditional timestamp format.
# To enable high precision timestamps, comment out the following line.
#
$ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat
# Filter duplicated messages
$RepeatedMsgReduction on
#
# Where to place spool and state files
#
$WorkDirectory /var/spool/rsyslog
#
# Include all config files in /etc/rsyslog.d/
#
$IncludeConfig /etc/rsyslog.d/*.conf
#
# Set the default permissions for all log files.
#
$FileOwner root
$FileGroup root
$FileCreateMode 0640
$DirCreateMode 0755
$Umask 0022
$PrivDropToUser root
$PrivDropToGroup root
###########################
#### Central log stuff ####
###########################
template (name="HostLogs" type="string" string="/var/log/remote/%FROMHOST%/%programname%.%$MONTH%-%$DAY%.log")
ruleset(name="remote"){
# action(type="omfile" file="/var/log/syslog")
action(type="omfile" DynaFile="HostLogs")
}
input(type="imtcp" port="514" ruleset="remote")
# input(type="imudp" port="1514" ruleset="remote")