This is very complicated process, especially for raw players.
There are several solutions to solve this problem for classic Sun Boxes.
1. unload the system disk and insert to another box with Solaris, then mount it, at last we can access /etc/passwd and do some modifications
2. If there's a DVD/CD rom in the box, we can boot the OS from the DVD/CD rom, then mount the system disk, and change it.
3. setup a network installation server, boot the crashed box from the network, then mount the disk, at last change it.
[@more@]Because T1000 is a new type of Box of Sun Company, which is so new that the disk cannot be identified by other boxes we have and it does include a DVD/CD rom, we have to use the third scheme to troubleshoot.
we use tssun(65.187) as the Boot Server, insert the latest Solaris 10 OS Disk to its DVD rom.
(# indicator for OS, -- indicator for comments)
#mount /cdrom
-- Share the s0 as NFS on the net, make sure NFS daemons nfsd and mountd have been started
--we can also modify the /etc/dfs/dfstab file with add a line as below
#share -F nfs -o ro,anon=0 /cdrom/sol_10_106_sparc/s0
#cd /cdrom/sol_10_106_sparc/s0/Solaris_10/Tools
#vi /etc/hosts and add a line 192.168.65.18 TIB-CDC-OA
--sun4v is the platform group name, which is important. Last week, we cannot solve this problem, the exact reason is that the OS Installation media we have is not the latest one and does not include these new sun4v type
#./add_install_client TIB-CDC-OA sun4v
(ok is the Operation indicator, and -- is the comment symbol)
--Start the TIB-CDC-OA from network with single user mode
--TIB-CDC-OA box broadcasts its request through the whole subnet, and the tssun(65.187) replies the request, at last the TIB-CDC-OA boot to the single user mode
ok boot net -s
--we use format command to get the identifier for the disk c0t0d0s0
#format
--mount the Disk as /a
#mount /dev/dsk/c0t0d0s0 /a
--move in the directory
#cd /a
--we found the /etc/passwd had been deleted
--we got one copy from Test2(65.12)
#ftp ...
--we set the env TERM to use vi
#TERM=vt100;export TERM
--modified the /etc/shadow to remove the content between 1th and 2th colon for root account.
#vi /etc/shadow
--reboot from hard disk
#reboot --disk
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/142423/viewspace-895977/ ,如需转载,请注明出处,否则将追究法律责任。