slackware-current/source/a/sysklogd/config/rc.syslog.new
Patrick J Volkerding 1e5164fb6d Mon Dec 18 20:22:40 UTC 2023
a/sysklogd-2.5.2-x86_64-2.txz:  Rebuilt.
  rc.syslog: be more graceful with the "restart" option.
  Thanks to opty.
l/gst-plugins-bad-free-1.22.8-x86_64-1.txz:  Upgraded.
l/gst-plugins-base-1.22.8-x86_64-1.txz:  Upgraded.
l/gst-plugins-good-1.22.8-x86_64-1.txz:  Upgraded.
l/gst-plugins-libav-1.22.8-x86_64-1.txz:  Upgraded.
l/gstreamer-1.22.8-x86_64-1.txz:  Upgraded.
n/c-ares-1.24.0-x86_64-1.txz:  Upgraded.
n/dhcpcd-10.0.6-x86_64-1.txz:  Upgraded.
n/openssh-9.6p1-x86_64-1.txz:  Upgraded.
n/traceroute-2.1.5-x86_64-1.txz:  Upgraded.
2023-12-18 21:59:19 +01:00

40 lines
720 B
Bash

#!/bin/sh
# Start/stop/restart the system logging daemon.
#
# Written for Slackware Linux by Patrick J. Volkerding <volkerdi@slackware.com>.
# Source default settings:
if [ -r /etc/default/syslogd ]; then
. /etc/default/syslogd
fi
syslogd_start() {
if [ -x /usr/sbin/syslogd ]; then
echo "Starting syslogd daemon: /usr/sbin/syslogd ${SYSLOGD_OPTS}"
/usr/sbin/syslogd $SYSLOGD_OPTS
fi
}
syslogd_stop() {
killall --ns $$ -TERM syslogd 2> /dev/null
}
syslogd_restart() {
syslogd_stop
timeout 1 pwait --ns $$ -U root -P 1 syslogd
syslogd_start
}
case "$1" in
'start')
syslogd_start
;;
'stop')
syslogd_stop
;;
'restart')
syslogd_restart
;;
*)
echo "usage $0 start|stop|restart"
esac