aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2006-07-20 18:17:21 +0000
committerBill Nottingham <notting@redhat.com>2006-07-20 18:17:21 +0000
commit6a8552e02f09eaa1c4d091e00e714a56f178d726 (patch)
treeab9d553747522adb6e9bb6b7fbe8eeb02b442c96
parent5293e49cac28a9af839cd0df96155b1140172637 (diff)
downloadinitscripts-6a8552e02f09eaa1c4d091e00e714a56f178d726.tar
initscripts-6a8552e02f09eaa1c4d091e00e714a56f178d726.tar.gz
initscripts-6a8552e02f09eaa1c4d091e00e714a56f178d726.tar.bz2
initscripts-6a8552e02f09eaa1c4d091e00e714a56f178d726.tar.xz
initscripts-6a8552e02f09eaa1c4d091e00e714a56f178d726.zip
quick quiz - which makes more sense, when entering single user mode:
- have 'single' start first, kill /etc/rc, and have it shut down all the services by itself - have /etc/rc kill services normally, and just run 'single' last? Yeah, I thought so.
-rw-r--r--Makefile2
-rwxr-xr-xrc.d/init.d/single21
2 files changed, 1 insertions, 22 deletions
diff --git a/Makefile b/Makefile
index a50247be..ed11c559 100644
--- a/Makefile
+++ b/Makefile
@@ -91,7 +91,7 @@ install:
ln -s ../init.d/halt $(ROOT)/etc/rc.d/rc0.d/S01halt
ln -s ../init.d/halt $(ROOT)/etc/rc.d/rc6.d/S01reboot
- ln -s ../init.d/single $(ROOT)/etc/rc.d/rc1.d/S00single
+ ln -s ../init.d/single $(ROOT)/etc/rc.d/rc1.d/S99single
ln -s ../rc.local $(ROOT)/etc/rc.d/rc2.d/S99local
ln -s ../rc.local $(ROOT)/etc/rc.d/rc3.d/S99local
diff --git a/rc.d/init.d/single b/rc.d/init.d/single
index 64c6806d..0ae9268e 100755
--- a/rc.d/init.d/single
+++ b/rc.d/init.d/single
@@ -16,30 +16,9 @@ if [ "$1" != "start" ]; then
exit 0
fi
-rm -f /var/lock/subsys/*
-
# this looks nicer
[ -x /usr/bin/clear ] && /usr/bin/clear
-# make sure modprobe is working
-if [ -f /proc/sys/kernel/modprobe ]; then
- sysctl -w kernel.modprobe="/sbin/modprobe" >/dev/null 2>&1
-fi
-
-# If they want to run something in single user mode, might as well run it...
-for i in /etc/rc1.d/S[0-9][0-9]* ; do
- # Check if the script is there.
- [ -x "$i" ] || continue
-
- # Reject backup files and files generated by rpm.
- case "$1" in
- *.rpmsave|*.rpmorig|*.rpmnew|*~|*.orig)
- continue;;
- esac
- [ "$i" = "/etc/rc1.d/S00single" ] && continue
- $i start
-done
-
# Now go to the single user level.
echo $"Telling INIT to go to single user mode."
exec init -t1 S