/etc/init.d/bootlogs is in initscripts 2.88dsf-59.9.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | #!/bin/sh
### BEGIN INIT INFO
# Provides: bootlogs
# Required-Start: hostname $local_fs
# Required-Stop:
# Should-Start: $x-display-manager gdm kdm xdm ldm sdm wdm nodm
# Default-Start: 1 2 3 4 5
# Default-Stop:
# Short-Description: Log file handling to be done during bootup.
# Description: Various things that don't need to be done particularly
# early in the boot, just before getty is run.
### END INIT INFO
PATH=/sbin:/usr/sbin:/bin:/usr/bin
[ "$DELAYLOGIN" ] || DELAYLOGIN=yes
. /lib/init/vars.sh
do_start () {
# Save kernel messages in /var/log/dmesg
if which dmesg >/dev/null 2>&1
then
[ -f /var/log/dmesg ] && savelog -q -p -c 5 /var/log/dmesg
dmesg -s 524288 > /var/log/dmesg
chgrp adm /var/log/dmesg || :
elif [ -c /dev/klog ]
then
[ -f /var/log/dmesg ] && savelog -q -p -c 5 /var/log/dmesg
dd if=/dev/klog of=/var/log/dmesg &
sleep 1
kill $!
[ -f /var/log/dmesg ] && { chgrp adm /var/log/dmesg || : ; }
fi
}
do_status () {
return 0
}
case "$1" in
start|"")
do_start
;;
restart|reload|force-reload)
echo "Error: argument '$1' not supported" >&2
exit 3
;;
stop)
# No-op
;;
status)
do_status
exit $?
;;
*)
echo "Usage: bootlogs [start|stop|status]" >&2
exit 3
;;
esac
:
|