免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3015 | 回复: 7
打印 上一主题 下一主题

求助!root忘记密码了,网上的方法用过了还是不行。很着急 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2011-10-30 13:12 |只看该作者 |倒序浏览
本帖最后由 feiniao222 于 2011-10-30 13:20 编辑

小弟的v240机器信息如下:

1.  format 信息如下,从信息上看不出是否已经作了镜像。似乎根盘时c1t0d0s0,不知道对不对。

# echo | format
Searching for disks...done


AVAILABLE DISK SELECTIONS:
       0. c1t0d0 <SUN72G cyl 14087 alt 2 hd 24 sec 424>
          /pci@1c,600000/scsi@2/sd@0,0
       1. c1t1d0 <SUN72G cyl 14087 alt 2 hd 24 sec 424>
          /pci@1c,600000/scsi@2/sd@1,0
       2. c1t2d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
          /pci@1c,600000/scsi@2/sd@2,0
       3. c1t3d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
          /pci@1c,600000/scsi@2/sd@3,0
Specify disk (enter its number): Specify disk (enter its number):

2.命令df -k显示的信息如下,好像看不到根盘信息。

# df -k
Filesystem            kbytes    used   avail capacity  Mounted on
/pci@1e,600000/ide@d/cdrom@0,0:b
                      174639  157917       0   100%    /
/devices                   0       0       0     0%    /devices
ctfs                       0       0       0     0%    /system/contract
proc                       0       0       0     0%    /proc
mnttab                     0       0       0     0%    /etc/mnttab
swap                 4006200     336 4005864     1%    /etc/svc/volatile
objfs                      0       0       0     0%    /system/object
swap                 4006416     552 4005864     1%    /tmp
/tmp/dev             4006416     552 4005864     1%    /dev
fd                         0       0       0     0%    /dev/fd
/devices/pci@1e,600000/ide@d/sd@0,0:a
                     3210366 3210366       0   100%    /cdrom
/cdrom/Solaris_10/Tools/Boot/usr
                     3210366 3210366       0   100%    /usr
/platform/sun4u-us3/lib/libc_psr/libc_psr_hwcap1.so.1
                      174639  157917       0   100%    /platform/sun4u-us3/lib/libc_psr.so.1
/platform/sun4u-us3/lib/sparcv9/libc_psr/libc_psr_hwcap1.so.1
                      174639  157917       0   100%    /platform/sun4u-us3/lib/sparcv9/libc_psr.so.1
swap                 4005864       0 4005864     0%    /tmp/root/var/run


3./dev/dsk/ 目录下,有如下信息:

# cd dev/dsk
# ls
c0t0d0s0  c0t0d0s5  c1t0d0s2  c1t0d0s7  c1t1d0s4  c1t2d0s1  c1t2d0s6  c1t3d0s3
c0t0d0s1  c0t0d0s6  c1t0d0s3  c1t1d0s0  c1t1d0s5  c1t2d0s2  c1t2d0s7  c1t3d0s4
c0t0d0s2  c0t0d0s7  c1t0d0s4  c1t1d0s1  c1t1d0s6  c1t2d0s3  c1t3d0s0  c1t3d0s5
c0t0d0s3  c1t0d0s0  c1t0d0s5  c1t1d0s2  c1t1d0s7  c1t2d0s4  c1t3d0s1  c1t3d0s6
c0t0d0s4  c1t0d0s1  c1t0d0s6  c1t1d0s3  c1t2d0s0  c1t2d0s5  c1t3d0s2  c1t3d0s7

3. /etc/shadow文件信息如下,我已经挂在c1t0d0s0后更改了root密码为空。

# cat shadow
root:NP:6445::::::
daemon:NP:6445::::::
bin:NP:6445::::::
sys:NP:6445::::::
adm:NP:6445::::::
lp:NP:6445::::::
uucp:NP:6445::::::
nuucp:NP:6445::::::
smmsp:NP:6445::::::
listen:*LK*:::::::
gdm:*LK*:::::::
webservd:*LK*:::::::
postgres:NP:::::::
svctag:*LK*:6445::::::
nobody:*LK*:6445::::::
noaccess:*LK*:6445::::::
nobody4:*LK*:6445::::::


4. /etc/passwd的信息如下,我没有做任何修改。
# cat passwd
root:0:0:Super-User:/:/sbin/sh
daemon:1:1::/:
bin:2:2::/usr/bin:
sys:3:3::/:
adm:4:4:Admin:/var/adm:
lp:71:8:Line Printer Admin:/usr/spool/lp:
uucp:5:5:uucp Admin:/usr/lib/uucp:
nuucp:9:9:uucp Admin:/var/spool/uucppublic:/usr/lib/uucp/uucico
smmsp:25:25:SendMail Message Submission Program:/:
listen:37:4:Network Admin:/usr/net/nls:
gdm:x:50:50:GDM Reserved UID:/:
webservd:x:80:80:WebServer Reserved UID:/:
postgres:x:90:90ostgreSQL Reserved UID:/:/usr/bin/pfksh
svctag:x:95:12:Service Tag UID:/:
nobody:x:60001:60001:NFS Anonymous Access User:/:
noaccess:x:60002:60002:No Access User:/:
nobody4:x:65534:65534:SunOS 4.x NFS Anonymous Access User:/:

5.  以下reboot是重启的信息。

# reboot
syncing file systems... done
rebooting...

SC Alert: Host System has Reset
Probing system devices
Probing memory
Probing I/O buses

Sun Fire V240, No Keyboard
Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
OpenBoot 4.18.5, 4096 MB memory installed, Serial #66583449.
Ethernet address 0:3:ba:f7:fb:99, Host ID: 83f7fb99.



Rebooting with command: boot                                          
Boot device: vx-rootdisk  File and args:
SunOS Release 5.9 Version Generic_122300-13 64-bit
Copyright 1983-2003 Sun Microsystems, Inc.  All rights reserved.
Use is subject to license terms.
Hardware watchdog enabled
Configuring ATM interfaces:
VxVM sysboot INFO V-5-2-3390 Starting restore daemon...
VxVM sysboot INFO V-5-2-3409 starting in boot mode...
NOTICE: VxVM vxdmp V-5-0-34 added disk array DISKS, datype = Disk

configuring IPv4 interfaces: bge0.
Hostname: yfvtdm10
VxVM  INFO V-5-2-3247 starting special volumes ( swapvol rootvol var opt ford u c3p10 )...
VxVM vxvm-startup2 INFO V-5-2-503 VxVM general startup...
The system is coming up.  Please wait.
/dev/vx/rdsk/bootdg/opt is clean
starting rpc services: rpcbind done.
Setting netmask of bge0 to 255.255.255.128
Setting default IPv4 interface for multicast: add net 224.0/4: gateway yfvtdm10
syslog service starting.
Starting IONA Orbix E2A services for domain openideas13
Setting environment for domain openideas13
IONA services logging to: /var/opt/iona/openideas13/logs
Starting iona_services.locator.yfvtdm10
Starting iona_services.node_daemon.yfvtdm10
Starting iona_services.naming.yfvtdm10
Finished.
Starting I-DEAS Resource Locking Daemon
Starting I-DEAS Resource Locking Daemon
nohup: cannot open/create nohup.out: Permission denied
Starting Orbix E2A services for the openideas11 domain
Sending output to nohup.out
Starting Orbix 6.3 services for the openideas13 domain
Sending output to nohup.out
Warning: OS level changed from 5.8 to 5.9.
Run /opt/SUNWsan/bin/san_recover
volume management starting.
Using /var/run
Oct 30 12:05:31 yfvtdm10 snmpXdmid: Error in Adding Row for Subscription Table Entry
Oct 30 12:05:31 yfvtdm10 snmpXdmid: Failed to add filter to SP for Event delivery
Could not enable logging for /cdrom/sol_10_807_sparc/s6 on /vol/dev/dsk/c0t0d0/sol_10_807_sparc/s6.
File system is mounted read only.
Please see the remount option described in mount_ufs(1M).
Could not enable logging for /cdrom/sol_10_807_sparc/s5 on /vol/dev/dsk/c0t0d0/sol_10_807_sparc/s5.
File system is mounted read only.
Please see the remount option described in mount_ufs(1Md in mount_ufs(1M).
Could not enable logging for /cdrom/sol_10_807_sparc/s1 on /vol/dev/dsk/c0t0d0/sol_10_807_sparc/s1.
File system is mounted read only.
Please see the remount option described in mount_ufs(1M).
Storing unknown to /var/run/psn
The system is ready.



各位,有什么办法帮我解决以下,很是着急啊。郁闷!

论坛徽章:
0
2 [报告]
发表于 2011-10-30 13:13 |只看该作者
请各位帮帮忙,小弟实在搞不了了,疯掉!

论坛徽章:
0
3 [报告]
发表于 2011-10-30 13:21 |只看该作者
希望大家给我看看,怎样才可以把root密码清掉。谢谢!

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
4 [报告]
发表于 2011-10-30 14:48 |只看该作者
在OK下打printenv 查看启动的硬盘顺序
在OK下setenv 可以指定启动硬盘,指定你改好密码的那一块
这样试试.

论坛徽章:
0
5 [报告]
发表于 2011-10-30 19:22 |只看该作者
boot  cdrom  -s
mount  /dev/dsk/c1t0d0s0  /mnt
cd  /mnt/etc
cat vfstab
看分区表中目录挂载情况,然后再请密码。如果做过镜像,两块盘都要清除shadow中的密码。

论坛徽章:
0
6 [报告]
发表于 2011-10-31 09:30 |只看该作者
如果做过镜像,需要修改另外一块硬盘的shadow文件,或者拆除镜像然后从c0t0d0启动然后进去再做镜像。

论坛徽章:
0
7 [报告]
发表于 2011-11-02 11:14 |只看该作者
试着拔出一块盘,再修改相关的文件,做了mirror直接手工改2个文件是不行的,虽然文件的内容改后是一样的
或者找张带VXVM环境的光盘启动,import rootdg,修改相关文件试试

论坛徽章:
0
8 [报告]
发表于 2011-11-02 14:32 |只看该作者
回复 7# calcm

谢谢大家的帮助,问题解决了!
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP