1#!/bin/sh 2# 3# 4 5# PROVIDE: dmesg 6# REQUIRE: mountcritremote FILESYSTEMS 7# BEFORE: DAEMON 8# KEYWORD: nojail 9 10. /etc/rc.subr 11 12name="dmesg" 13desc="Save kernel boot messages to disk" 14rcvar="dmesg_enable" 15dmesg_file="/var/run/dmesg.boot" 16start_cmd="do_dmesg" 17stop_cmd=":" 18 19do_dmesg() 20{ 21 rm -f ${dmesg_file} 22 ( umask 022 ; /sbin/dmesg $rc_flags > ${dmesg_file} ) 23} 24 25load_rc_config $name 26 27# doesn't make sense to run in a svcj 28dmesg_svcj="NO" 29 30run_rc_command "$1" 31