Recovery of root password with SDS mirrored rootdisk
This assumes that c0t0d0s0 is rootdisk and c0t1d0s0 is root mirror.
/dev/md/dsk/d0 is / device, d10 is c0t0d0s0 and d20 is c0t1d0s0
- boot the machine from cdrom or off the net into single user mode.
- fsck -o p /dev/dsk/c0t0d0s0 (or your root device if different)
- mount /dev/dsk/c0t0d0s0 /a
- vi /a/etc/system - comment out rootdev by putting * in front
- vi /a/etc/vfstab - comment out /dev/md/dsk/d0 entry (or whatever
metadevice you use for /) and add raw device entry back in
- vi /a/etc/shadow and fix root password
- reboot (off your primary rootdevice - which it will do automatically
at this point by just typing
reboot
)
* at this stage, your d0 two submirrors are probably both listed
in a "needing synchronization" phase - so you may not be able to
run metadetach - this procedure works either way.
- metaclear d0. (clear the current mirror setup)
- metainit d0 -m d10 (setup d0 to be c0t0d0s0 submirror as primary)
- metaroot d0 (this will reenable /etc/system boot device and also fix
/etc/vfstab for you)
- reboot - you will now be running once again off disksuite root mirror
- metattach d0 d20
Why do metattach after reboot? because it can take a long time to
synchronize and if you do it before the reboot, it's probably better
to wait until it's complete, which delays recovery.