![]() |
The comman ``linux single'' during the boot put your computer into runlevel 1, or single-user mode. You will be logged in as root , and you're not supposed to enter any passwords as you normally are. A "backdoor" into Linux for you as root so that you have a chance to correct any errors that might occur.
Here are some examples:
Lets say that you run kdm, gdm or xdm via /etc/inittab. If you by accident make an error in the setup of X or inittab the result might be that you never get to the graphical login because the bootprocess never get that far. That's when "linux single" is there to help you. It boots Linux to a root prompt so that you can correct the errors and reboot the computer.
You're running as root (you know better don't you?), and you leave a process running that logs through syslog. It fills up your log file, and in turn your partition. Now you can't log in. In single user mode, you can fix it.
You forgot your root password and need to reset it.
If you are using LILO, at the LILO boot prompt (if you are using the graphical LILO, press [Ctrl]x to exit the graphical screen and go to the boot: prompt);
boot: linux singleThe GRUB boot loader doesn't have a default boot prompt. You can choose ``e'' when the menu displays, to edit the boot paramters, select the line that starts with kernel, for the kernel you want to boot. Go to the end of the line and type single as a seperate word (press the [Spacebar] and then type single. Press Enter to exit edit mode. Back at the GRUB screen, type b to boot into single user mode. You might find it simpler to edit grub.conf and add a single user login menu item similar to this:
title Single User Mode
root (hd0,0)
kernel /vmlinuz-2.4.20-8 single rw root=LABEL=/ hdc=ide-scsi
initrd /initrd-2.4.20-8.imgOf course you don't want to copy this verbatim, since your system will be different. This is only an example.