Valdis.Kletnieks@vt.edu wrote:
On Tue, 18 Jul 2006 13:36:00 EDT, Nick Baronian said:
I have a RedHat Ent.4 box I want to put syslog-ng on. Should I remove syslogd (sysklogd) first?
No. Careful planning will avoid installing one on top of the other, and you want the old syslog around Just In Case.
If so how do I get syslog-ng to handle the cron (vixie) and initscripts?
# cd /etc/init.d # cp syslog syslog-ng # chkconfig syslog off
By using a separate syslog-ng init.d script we found that we sometimes accidentally started syslog by doing an "/etc/init.d/syslog restart" rather than a "/etc/init.d/syslog-ng restart". No errors get thrown, but we end up having two processes reading from /dev/log which results in logging stopping for both syslog and syslog-ng. Obviously not what we want to happen. To avoid this you can just make /etc/init.d/syslog start/stop syslog-ng but you run the risk of an up2date replacing the /etc/init.d/syslog script when a new version of syslog gets updated. We found a better approach was to "hack" the /etc/sysconfig/syslog file to add at the end if [ "$1" != "stop" ]; then if [ "$1" != "status" ]; then echo "This system runs syslog-ng" exit 1 fi fi so that when /etc/init.d/syslog is invoked, this file runs and alerts the user to the fact that syslog-ng has replaced syslog-ng on the system. This file is not replaced when syslog is updated. You could add other stuff, such as redirect to the syslog-ng startup script. In our environment we wanted to train the sysadmins to use the /etc/init.d/syslog-ng script. If you are interested, I can send you our syslog-ng init.d script. -- Evan Rempel erempel@uvic.ca Senior Programmer Analyst 250.721.7691 Computing Services University of Victoria