Red Hat Bugzilla – Bug 443554
Add "s" option to boot single user mode from grub command line
Last modified: 2014-06-18 04:46:18 EDT
Description of problem:
Historycally we can boot with single user mode from grub command line
adding "s". But after changing to upstart, only "-s", "single" and "S" are
Version-Release number of selected component (if applicable):
always when type "s"
Steps to Reproduce:
1. enter grub menu
2. append "s" to command line
default runlevel (3 or 5)
single user mode (1)
Here is a proposed patch.
--- /etc/event.d/rcS~ 2008-04-05 00:49:20.000000000 +0900
+++ /etc/event.d/rcS 2008-04-22 16:32:45.000000000 +0900
@@ -20,7 +20,7 @@
[ -z "$runlevel" ] && runlevel="3"
for t in $(cat /proc/cmdline); do
case $t in
- -s|single|S) runlevel="S" ;;
+ -s|single|S|s) runlevel="S" ;;
[1-9]) runlevel="$t" ;;
I'm not sure why 's' worked before. From the init manpage:
Init accepts the following flags:
-s, S, single
Single user mode boot. In this mode /etc/inittab is examined and the
bootup rc scripts are usually run before the single user mode shell is
From the code:
if (!strcmp(argv[f], "single") || !strcmp(argv[f], "-s"))
dfl_level = 'S';
So, I don't think 's' was ever really supported.
Aha, found it:
if (dfl_level == 's') dfl_level = 'S';
Yay for undocumented features.
Which man page you are referring ?
On F8, LANG=C man 8 init said
Runlevel S or s bring the system to single user mode and do not require
an /etc/inittab file. In single user mode, a root shell is opened on
$ rpm -qf /usr/share/man/man8/init.8.gz
Will be in 0.3.9-14.
Sorry. Please ignore Comment #3.
And thank you for adding undocumented feature.
I've been using this option for over 10 years.
It's so thanksfull to keep compatibility.