diff options
author | obrien <obrien@FreeBSD.org> | 2001-06-16 07:16:14 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2001-06-16 07:16:14 +0000 |
commit | afad76ee76d3a58cf84a1bc6fb12c55552bc5563 (patch) | |
tree | fd0686de98f61bd8f248380d2e5aee4905a258bb /etc/rc.d/sysdb | |
parent | 3cf81c35aeec9a68f04a9ff772f9d4eb26e3605b (diff) | |
download | FreeBSD-src-afad76ee76d3a58cf84a1bc6fb12c55552bc5563.zip FreeBSD-src-afad76ee76d3a58cf84a1bc6fb12c55552bc5563.tar.gz |
Import the NetBSD 1.5 RC system.
Note that `rc' and `rc.shutdown' could not be imported because we already
have files with those names.
Diffstat (limited to 'etc/rc.d/sysdb')
-rwxr-xr-x | etc/rc.d/sysdb | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/etc/rc.d/sysdb b/etc/rc.d/sysdb new file mode 100755 index 0000000..29b0d3b --- /dev/null +++ b/etc/rc.d/sysdb @@ -0,0 +1,34 @@ +#!/bin/sh +# +# $NetBSD: sysdb,v 1.6 2000/10/09 05:02:14 nisimura Exp $ +# + +# PROVIDE: sysdb +# REQUIRE: mountcritremote + +. /etc/rc.subr + +name="sysdb" +start_cmd="sysdb_start" +stop_cmd=":" + +sysdb_start() +{ + # Build ps databases. If this kernel supports + # machdep.booted_kernel, use that to build the KVM db so dmesg + # will run work when we boot /netbsd.new, etc. + # + echo "Building databases..." + booted_kernel=`sysctl -n machdep.booted_kernel 2>/dev/null` + kvm_mkdb ${booted_kernel:-/netbsd} + dev_mkdb + + # Re-create /var/run/utmp, which is deleted by mountcritlocal + # but can't be recreated by it because install and chown may + # not be available then (possibly no /usr). + # + install -c -m 664 -g utmp /dev/null /var/run/utmp +} + +load_rc_config $name +run_rc_command "$1" |