About once a year, I'll find a way to lock myself out of a Solaris system. Here's how to get out of this scenario. You'll need a Solaris 11 Live CD or Live USB stick.Mount the solaris boot environment in a temporary directory Edit the shadow file Find your username and remove the password hash Allow empty passwords at login Update the boot archive Reboot and remove the Live CD/USB from system
- Boot up from the Live CD/USB
- Select the 'Text Console' option from the GRUB menu
- Login to the solaris console using the username/password of jack/jack
- Switch to root
$ sudo supassword jack
# beadm mount solaris /a
# vi /a/etc/shadow
Convert username:iEwei23SamPleHashonf0981:15746::::::17216to username::15746::::::17216
$ vi /a/etc/default/loginSwitch this line PASSREQ=YESto PASSREQ=NO
# bootadm update-archive -R /a
# rebootIf prompted for a password, hit return since this has now been blanked.