当前位置: 技术问答>linux和unix
修改了PASSWD把登陆的SHELL给改错了结果ROOT无法登陆,可有办法补救啊??
来源: 互联网 发布时间:2015-05-09
本文导语: 给位大哥,由于小弟想把ROOT的默认SHELL改为CSH,于是去修改PASSWD文件,结果没看清把默认的SHELL改成了CHS,导致登陆的时候显示无法找到SHELL登陆,进不了SHELL我无法再改回原来的SHELL。我还有个USER的帐号可以登陆到BAS...
给位大哥,由于小弟想把ROOT的默认SHELL改为CSH,于是去修改PASSWD文件,结果没看清把默认的SHELL改成了CHS,导致登陆的时候显示无法找到SHELL登陆,进不了SHELL我无法再改回原来的SHELL。我还有个USER的帐号可以登陆到BASH但却没有权限修改PASSWD文件,想在LIUNX下MOUNT FREEBSD的分区修改却不知道怎么MOUNT。各位大哥给小弟想个办法啊,很急啊,我不想重装系统啊,我机器里有三个系统一重装就要都重搞。帮帮我啊!!!!
|
引导时能进单用户吗?在
Hit [Enter] to boot immediately, or any other key for command prompt.
Booting [kernel] in 10 seconds...
提示时按空格,然后执行boot -s试试。
Hit [Enter] to boot immediately, or any other key for command prompt.
Booting [kernel] in 10 seconds...
提示时按空格,然后执行boot -s试试。
|
At this prompt type 'boot -s' which will get you into single
user mode. From there 'mount -a' to mount all the drives r/w.
You can remount just the root partition if you like, but this
will be easiest. Then use passwd to change root's password
to whatever you want.
user mode. From there 'mount -a' to mount all the drives r/w.
You can remount just the root partition if you like, but this
will be easiest. Then use passwd to change root's password
to whatever you want.