Reset the Solaris root password June 13, 2008Posted by claudio in Uncategorized.
Tags: password, security, Solaris
Forgetting the root password (or being replaced without you knowing it). Pretty silly when it happens, but it does happen. Follow this steps if you need to reset the root password of a Solaris system.
Use the dvd or the “software cd 1 of 2″ to boot in single user mode:
From ok prompt:
ok boot cdrom -s
When the system is booted:
# mount /dev/dsk/c0t0d0s0 /a (mount -F ufs -rw /dev/dsk/c0t0d0s0 /a if problems)
# cd /a/etc
# export TERM
# vi shadow
=> delete passwd entry (13 chars) in the line for the root account (between the :: )
=> save and exit:
# cd /
# umount /a
# init 6
After reboot – log in as root with no password, open up a terminal, type passwd, and create a new passwd.