4
# Required-Start: mountdevsubfs
5
# X-Start-Before: hostname keymap keyboard-setup procps pcmcia hwclock hwclockfirst hdparm hibernate-clean
9
# Short-Description: Start or stop bootlogd.
10
# Description: Starts or stops the bootlogd log program
11
# which logs boot messages.
14
PATH=/sbin:/bin # No remote fs at start
16
[ -x "$DAEMON" ] || exit 0
20
[ -r /etc/default/bootlogd ] && . /etc/default/bootlogd
23
. /lib/lsb/init-functions
25
# Because bootlogd is broken on some systems, we take the special measure
26
# of requiring it to be enabled by setting an environment variable.
27
case "$BOOTLOGD_ENABLE" in
33
# Previously this script was symlinked as "stop-bootlogd" which, when run
34
# with the "start" argument, should stop bootlogd. Now stop-bootlogd is
35
# a distinct script, but for backward compatibility this script continues
36
# to implement the old behavior.
38
SCRIPTNAME=${SCRIPTNAME#[SK]??}
42
[ "$ACTION" = start ] && ACTION=stop
49
log_daemon_msg "Starting $DESC" "$NAME"
53
start-stop-daemon --start --quiet --exec $DAEMON -- \
57
$DAEMON $BOOTLOGD_OPTS
63
PATH=/bin:/sbin:/usr/bin:/usr/sbin
64
log_daemon_msg "Stopping $DESC" "$NAME"
65
start-stop-daemon --oknodo --stop --quiet --exec $DAEMON
69
if [ -f /var/log/boot ] && [ -f /var/log/boot~ ]
71
[ "$VERBOSE" = no ] || log_action_begin_msg "Moving boot log file"
72
# bootlogd writes to boot, making backup at boot~
75
savelog -q -p -c 5 boot \
80
[ "$VERBOSE" = no ] || log_action_end_msg $ES
84
/etc/init.d/bootlogd stop
85
/etc/init.d/bootlogd start
88
status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $?
91
echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload|status}" >&2