Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-1-5]: src/etc/rc.d pull up the following:
details: https://anonhg.NetBSD.org/src/rev/7aa221139d1c
branches: netbsd-1-5
changeset: 489221:7aa221139d1c
user: lukem <lukem%NetBSD.org@localhost>
date: Wed Aug 23 12:32:17 2000 +0000
description:
pull up the following:
etc/rc.d/Makefile 1.12
etc/rc.d/fsck 1.1
etc/rc.d/fsck.sh REMOVE
replace fsck.sh with fsck (using kill -TERM $$ to stop autoboot).
approved: thorpej
diffstat:
etc/rc.d/Makefile | 19 ++++++++-------
etc/rc.d/fsck | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
etc/rc.d/fsck.sh | 57 ----------------------------------------------
3 files changed, 78 insertions(+), 66 deletions(-)
diffs (161 lines):
diff -r 7c4236f2ce89 -r 7aa221139d1c etc/rc.d/Makefile
--- a/etc/rc.d/Makefile Wed Aug 23 12:29:37 2000 +0000
+++ b/etc/rc.d/Makefile Wed Aug 23 12:32:17 2000 +0000
@@ -1,14 +1,15 @@
-# $NetBSD: Makefile,v 1.7.2.2 2000/08/09 18:50:30 lukem Exp $
+# $NetBSD: Makefile,v 1.7.2.3 2000/08/23 12:32:17 lukem Exp $
FILES= DAEMON LOGIN NETWORK SERVERS accounting amd apmd bootparams \
- bootconf.sh ccd cleartmp cron dhclient dhcpd dhcrelay dmesg fsck.sh \
- gated inetd ipfilter ipmon ipnat ipsec kdc ldconfig lkm1 lkm2 \
- lkm3 local lpd mopd \
- motd mountall mountcritlocal mountcritremote mountd mrouted named \
- network nfsd nfslocking ntpd ntpdate rpcbind postfix ppp pwcheck quota \
- raidframe rarpd rbootd root route6d routed rtadvd rtsold rwho savecore \
- screenblank sendmail swap1 swap2 sysdb sysctl syslogd timed \
- ttys virecover wscons xdm xfs ypbind yppasswdd ypserv
+ bootconf.sh ccd cleartmp cron dhclient dhcpd dhcrelay dmesg \
+ fsck gated inetd ipfilter ipmon ipnat ipsec kdc ldconfig \
+ lkm1 lkm2 lkm3 local lpd mopd motd mountall mountcritlocal \
+ mountcritremote mountd mrouted named network nfsd nfslocking \
+ ntpd ntpdate rpcbind postfix ppp pwcheck quota raidframe \
+ rarpd rbootd root route6d routed rtadvd rtsold rwho savecore \
+ screenblank sendmail securelevel swap1 swap2 sysdb sysctl \
+ syslogd timed ttys virecover wscons xdm xfs ypbind yppasswdd \
+ ypserv
FILESDIR= /etc/rc.d
FILESMODE= ${BINMODE}
diff -r 7c4236f2ce89 -r 7aa221139d1c etc/rc.d/fsck
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/etc/rc.d/fsck Wed Aug 23 12:32:17 2000 +0000
@@ -0,0 +1,68 @@
+#!/bin/sh
+#
+# $NetBSD: fsck,v 1.1.2.2 2000/08/23 12:32:17 lukem Exp $
+#
+
+# PROVIDE: fsck
+# REQUIRE: localswap
+
+. /etc/rc.subr
+
+name="fsck"
+start_cmd="fsck_start"
+stop_cmd=":"
+
+stop_boot()
+{
+ # Terminate the process (which may include the parent /etc/rc)
+ # if booting directly to multiuser mode.
+ #
+ if [ "$autoboot" = yes ]; then
+ kill -TERM $$
+ fi
+ exit 1
+}
+
+fsck_start()
+{
+ if [ -e /fastboot ]; then
+ echo "Fast boot: skipping disk checks."
+ elif [ "$autoboot" = yes ]; then
+ # During fsck ignore SIGQUIT
+ trap : 3
+
+ echo "Automatic boot in progress: starting file system checks."
+ fsck -p
+ case $? in
+ 0)
+ ;;
+ 2)
+ stop_boot
+ ;;
+ 4)
+ echo "Rebooting..."
+ reboot
+ echo "Reboot failed; help!"
+ stop_boot
+ ;;
+ 8)
+ echo "Automatic file system check failed; help!"
+ stop_boot
+ ;;
+ 12)
+ echo "Boot interrupted."
+ stop_boot
+ ;;
+ 130)
+ stop_boot
+ ;;
+ *)
+ echo "Unknown error; help!"
+ stop_boot
+ ;;
+ esac
+ fi
+}
+
+load_rc_config $name
+run_rc_command "$1"
diff -r 7c4236f2ce89 -r 7aa221139d1c etc/rc.d/fsck.sh
--- a/etc/rc.d/fsck.sh Wed Aug 23 12:29:37 2000 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,57 +0,0 @@
-#!/bin/sh
-#
-# $NetBSD: fsck.sh,v 1.2 2000/04/26 05:13:51 thorpej Exp $
-#
-
-# PROVIDE: fsck
-# REQUIRE: localswap
-
-fsck_start()
-{
- if [ -e /fastboot ]; then
- echo "Fast boot: skipping disk checks."
- elif [ "$autoboot" = yes ]; then
- # During fsck ignore SIGQUIT
- trap : 3
-
- echo "Automatic boot in progress: starting file system checks."
- fsck -p
- case $? in
- 0)
- ;;
- 2)
- exit 1
- ;;
- 4)
- echo "Rebooting..."
- reboot
- echo "Reboot failed; help!"
- exit 1
- ;;
- 8)
- echo "Automatic file system check failed; help!"
- exit 1
- ;;
- 12)
- echo "Boot interrupted."
- exit 1
- ;;
- 130)
- exit 1
- ;;
- *)
- echo "Unknown error; help!"
- exit 1
- ;;
- esac
-
- # Reset SIGQUIT handler.
- trap "echo 'Boot interrupted.'; exit 1" 3
- fi
-}
-
-case "$1" in
-*start)
- fsck_start
- ;;
-esac
Home |
Main Index |
Thread Index |
Old Index