mirror of
https://git.linuxfromscratch.org/lfs.git
synced 2025-06-19 11:49:20 +01:00
Update to xz-5.2.0. Update to binutils-2.25. Update comments for sysklogd boot script. git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@10808 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
83 lines
1.8 KiB
Bash
83 lines
1.8 KiB
Bash
#!/bin/sh
|
|
########################################################################
|
|
# Begin sysklogd
|
|
#
|
|
# Description : Sysklogd loader
|
|
#
|
|
# Authors : Gerard Beekmans - gerard@linuxfromscratch.org
|
|
# DJ Lucas - dj@linuxfromscratch.org
|
|
# Update : Bruce Dubbs - bdubbs@linuxfromscratch.org
|
|
#
|
|
# Version : LFS 7.0
|
|
#
|
|
########################################################################
|
|
|
|
### BEGIN INIT INFO
|
|
# Provides: $syslog
|
|
# Required-Start: localnet
|
|
# Should-Start:
|
|
# Required-Stop: $local_fs sendsignals
|
|
# Should-Stop:
|
|
# Default-Start: 3 4 5
|
|
# Default-Stop: 0 1 2 6
|
|
# Short-Description: Starts kernel and system log daemons.
|
|
# Description: Starts kernel and system log daemons.
|
|
# /etc/fstab.
|
|
# X-LFS-Provided-By: LFS
|
|
### END INIT INFO
|
|
|
|
# Note: sysklogd is not started in runlevel 2 due to possible
|
|
# remote logging configurations
|
|
|
|
. /lib/lsb/init-functions
|
|
|
|
case "${1}" in
|
|
start)
|
|
log_info_msg "Starting system log daemon..."
|
|
parms=${SYSKLOGD_PARMS-'-m 0'}
|
|
start_daemon /sbin/syslogd $parms
|
|
evaluate_retval
|
|
|
|
log_info_msg "Starting kernel log daemon..."
|
|
start_daemon /sbin/klogd
|
|
evaluate_retval
|
|
;;
|
|
|
|
stop)
|
|
log_info_msg "Stopping kernel log daemon..."
|
|
killproc /sbin/klogd
|
|
evaluate_retval
|
|
|
|
log_info_msg "Stopping system log daemon..."
|
|
killproc /sbin/syslogd
|
|
evaluate_retval
|
|
;;
|
|
|
|
reload)
|
|
log_info_msg "Reloading system log daemon config file..."
|
|
pid=`pidofproc syslogd`
|
|
kill -HUP "${pid}"
|
|
evaluate_retval
|
|
;;
|
|
|
|
restart)
|
|
${0} stop
|
|
sleep 1
|
|
${0} start
|
|
;;
|
|
|
|
status)
|
|
statusproc /sbin/syslogd
|
|
statusproc klogd
|
|
;;
|
|
|
|
*)
|
|
echo "Usage: ${0} {start|stop|reload|restart|status}"
|
|
exit 1
|
|
;;
|
|
esac
|
|
|
|
exit 0
|
|
|
|
# End sysklogd
|