OK boot cdrom -s
or
OK boot net -s
This will boot the server from the CD or Jumpstart server and launch a single user mode (No Password).
Mount the root file system (assume /dev/dsk/c0t0d0s0 here) onto /a
solaris# mount /dev/dsk/c0t0d0s0 /a
NOTE: /a is a temporary mount point that is available when you boot from CD or a JumpStart server
Now, with the root file system mounted on /a. All you need to do is to edit the shadow file and remove the encrypted password for root.
solaris# vi /a/etc/shadow
Now, exit the mounted filesystem, unmount the root filesystem and reboot the system to single-user mode booting of the disk.
solaris# cd /
solaris# umount /a
solaris# init s
This should boot of the disk and take you to the single-user mode. Press enter at the prompt to enter a password for root.
This should allow you to login to the system. Once in, set the password and change to multi-user mode.
NOTE: Single-User mode is only to ensure that the root user without password is not exposed to others if started in multi-user mode before being set with a new password.
solaris# passwd root
solaris# reboot
This should do. You should now be able to logon with the new password set for root
No comments:
Post a Comment