- 论坛徽章:
- 1
|
今天一个朋友给我电话问我在x86 下面如何进入单用户.
有日子没有使用了差点给忘记了.后来找了一下资料现在放在blog里面省去自己忘记了.
现在发现自己的记忆力实在是太完蛋了.
x86: How to Boot a System to Run Level S (Single-User
Level)
Use this procedure to boot a system that is currently at run level 0 to run
level S.
Steps
If the system displays the Press any key
to reboot prompt, press any key to reboot the system.
You can
also use the Reset button at this prompt. If the system is shut down, turn the system
on with the power switch.
The Current Boot Parameters menu is displayed
after a few minutes.
Type b -s to boot the system to run level S. Press
Enter.
If you do not make a selection within five seconds, the system
is automatically booted to run level 3.
Type the superuser password, if prompted.
Verify that the system is at run level S.
# who -r
. run-level S Jul 19 14:37 S 0 3
Perform the maintenance task that required the
run level change to S.
After you complete the system maintenance task,
type Control-D to bring the system to the multiuser state.
Example 12–4 x86: Booting a System to Run Level S (Single-User Level)
Press any key to reboot.
Resetting...
.
.
.
Initializing system
Please wait...
>>
Boot path: /pci@0,0/pci-ide@7,1/ide@0/cmdk@0,0:a
Boot args:
Type b [file-name] [boot-flags] to boot with options
or i to enter boot interpreter
or to boot with defaults
>>
Select (b)oot or (i)nterpreter: b -s
SunOS Release 5.10 Version amd64-gate-2004-09-30 32-bit
Copyright 1983-2004 Sun Microsystems, Inc. All rights reserved.
Use is subject to license terms.
DEBUG enabled
Booting to milestone "milestone/single-user:default".
Hostname: venus
NIS domain name is example.com
Requesting System Maintenance Mode
SINGLE USER MODE
Root password for system maintenance (control-d to bypass): xxxxxx
Entering System Maintenance Mode
.
.
.
# who -r
. run-level S Jul 19 14:37 S 0 3
(Perform some maintenance task)
# ^D
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/12/showart_51218.html |
|