Information
By default, syslog on RHEL5 does not listen for log messages coming in from remote systems. The -r flag can be used to enable this ability and the -s option can be used to strip the domain name from incoming messages to reduce redundant information in log files.
Rationale:
The guidance in the section ensures that remote log hosts are configured to only accept syslog data from hosts within the specified domain and that those systems that are not designed to be log hosts do not accept any remote syslog messages. This provides protection from spoofed log data and ensures that system administrators are reviewing reasonably complete syslog data in a central location.
**NOTE:**Since syslog uses UDP to send messages to a remote host, there is no guarantee that the remote host will actually receive all the data. Log messages may be lost, especially on busy sites.
Solution
For each host designated as a log host, edit the /etc/sysconfig/syslog file and add the following line:
SYSLOGD_OPTIONS='-m 0 -r -s <LOGHOST>'
Execute the following command to restart syslogd
# pkill -HUP syslogd
For hosts that are not designated log hosts, edit the /etc/sysconfig/syslog file and add the following line:
SYSLOGD_OPTIONS='-m 0'
Execute the following command to restart syslogd
# pkill -HUP syslogd
Default Value:
OS Default: No