[syslog-ng] Redhat init script?

georg.funke@netcologne.de georg.funke@netcologne.de
Thu, 21 Oct 1999 10:23:49 +0200 (CEST)


---1463786495-1804289383-940494237=:1874
Content-Type: TEXT/plain; charset=us-ascii

On 21 Oct, David Robinson wrote:
> Has anyone made up a standard syslog-ng start/stop init script for Redhat 6?
> 
> I noticed there was a debian one..
> 
> I'm currently just starting syslog-ng from the rc.local script.
> 
> If not I'll create one but I don't want to do it if someone has already done it.
> 

Hi,

here is one. It works with Redhat 6.0/6.1

	Georg

-- 
Georg Funke
Crowns & Flames SDC Cologne, Germany; http://www.geocities.com/Colosseum/4893
"Friendship is Square Dancing's greatest Reward"

---1463786495-1804289383-940494237=:1874
Content-Type: TEXT/plain; CHARSET=US-ASCII
Content-ID: syslog-ng
Content-Description: syslog-ng

#!/bin/sh
#
# syslog        Starts syslog-ng
#
# chkconfig: 345 11 70
# description: syslog-ng is a enhanced system and kernel logging daemon
# Author:       Georg Funke, <georg.funke@netcologne.de>

# Source function library.
. /etc/rc.d/init.d/functions

[ -f /usr/sbin/syslog-ng ] || exit 0

# See how we were called.
case "$1" in
  start)
	echo -n "Starting system loggers: "
	daemon syslog-ng -f /etc/syslog-ng/syslog-ng.conf
	echo
	touch /var/lock/subsys/syslog-ng
	;;
  stop)
	echo -n "Shutting down system loggers: "
	killproc syslog-ng
	echo
	rm -f /var/lock/subsys/syslog-ng
	;;
  restart)
	$0 stop
	$0 start
	;;
  reload)
	echo -n "Reloading syslog-ng: "
	killproc syslog-ng -HUP
	echo
	;;
  *)
	echo "Usage: syslog {start|stop|restart|reload}"
	exit 1
esac

exit 0


---1463786495-1804289383-940494237=:1874--