LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (http://www.linuxquestions.org/questions/linux-server-73/)
-   -   syslog client to log to syslog-ng and itself (http://www.linuxquestions.org/questions/linux-server-73/syslog-client-to-log-to-syslog-ng-and-itself-619233/)

noir911 02-06-2008 11:38 PM

syslog client to log to syslog-ng and itself
 
I am pointing one of my syslog client to a syslog-ng server. I want to log all message on the client itself AND on the syslog-ng server as well. Is there any easy way to do this? This is my current config file -

*.info;mail.none;authpriv.none;cron.none /var/log/messages
*.info;mail.none;authpriv.none;cron.none @192.168.25.11

authpriv.* /var/log/secure

mail.* -/var/log/maillog

cron.* /var/log/cron

*.emerg *

uucp,news.crit /var/log/spooler

local7.* /var/log/boot.log

OuterVillage.com 02-08-2008 10:51 AM

[QUOTE=noir911;3048619]I am pointing one of my syslog client to a syslog-ng server. I want to log all message on the client itself AND on the syslog-ng server as well. Is there any easy way to do this? This is my current config file -

*.info;mail.none;authpriv.none;cron.none /var/log/messages
*.info;mail.none;authpriv.none;cron.none @192.168.25.11



I'm assuming your remote log server is configured to accept remote logging. Remember to edit your /etc/sysconfig/syslog file on the remote log server and add the following options:

SYSLOGD_OPTIONS="-r -m 0"

The config file you have should work and be sending logs to 192.168.25.11 assuming the above is setup correctly.

A couple of things you should look out for when setting up the syslog.conf file on the client. I've noticed that it is very picky with white space. Don't cut'n'paste into the config file. Make sure you insert the tabs manually before the @192.168.25.11. Also don't forget to restart syslogd on the client.
Let me know if that helps.


All times are GMT -5. The time now is 04:10 PM.