MAN page from Fedora 16 sysvinit-tools-2.88-5.dsf.fc16.x86_64.rpm
SULOGIN
Section: Linux System Administrator's Manual (8)
Updated: 17 Jan 2006
Index NAME
sulogin - Single-user login
SYNOPSIS
sulogin[
-e ][
-p ][
-t SECONDS ][
TTY ]
DESCRIPTION
sulogincan be invoked by
init(8) when the system goes into single user mode.(This is done through an entry in
inittab(5).)
Init alsotries to execute
sulogin whenthe boot loader (e.g.,
grub(8))passes it the
-b option.
The user is prompted
- Give root password for system maintenance
(or type Control-D for normal startup):
sulogin will be connected to the current terminal, or to theoptional device that can be specified on the command line(typically /dev/console).
If the -t option is used then the program only waitsthe given number of seconds for user input.
If the -p option is used then the single-user shell is invokedwith a dash as the first character in argv[0].This causes the shell process to behave as a login shell.The default is not to do this,so that the shell will not read /etc/profileor $HOME/.profile at startup.
After the user exits the single-user shell,or presses control-D at the prompt,the system will (continue to) boot to the default runlevel.
ENVIRONMENT VARIABLES
sulogin looks for the environment variable
SUSHELL or
sushell to determine what shell to start. If the environment variableis not set, it will try to execute root's shell from /etc/passwd. If thatfails it will fall back to
/bin/sh.
This is very valuable together with the -b option to init. To bootthe system into single user mode, with the root file system mounted read/write,using a special "fail safe" shell that is statically linked (this exampleis valid for the LILO bootprompt)
boot: linux -b rw sushell=/sbin/sash
FALLBACK METHODS
sulogin checks the root password using the standard method (getpwnam)first.Then, if the
-e option was specified,
sulogin examines these files directly to find the root password:
/etc/passwd,
/etc/shadow (if present)
If they are damaged or nonexistent, sulogin will start a root shellwithout asking for a password. Only use the -e option if youare sure the console is physically protected against unauthorized access.
AUTHOR
Miquel van Smoorenburg <miquelsAATTcistron.nl>
SEE ALSO
init(8),
inittab(5).
Index
- NAME
- SYNOPSIS
- DESCRIPTION
- ENVIRONMENT VARIABLES
- FALLBACK METHODS
- AUTHOR
- SEE ALSO
This document was created byman2html,using the manual pages.