| |
| |
http://www.brandonhutchinson.com/Mirroring_disks_with_DiskSuite.html
# format c0t0d0 Use the partition tool (=> "p <enter>, p <enter>"!) to setup the slices. We assume the following slice setup afterwards: # Tag Flag Cylinders Size Blocks 1. Copy the partition table of the first disk to its future mirror disk # prtvtoc /dev/rdsk/c0t0d0s2 fmthard -s - /dev/rdsk/c0t1d0s2 2. Create at least two state database replicas on each disk # metadb -a -f -c 2 c0t0d0s3 c0t1d0s3 Check the state of all replicas with metadb: # metadb Notes: A state database replica contains configuration and state information about the meta devices. Make sure that always at least 50% of the replicas are active!
# metainit -f d10 1 1 c0t0d0s0 Run metaroot to prepare /etc/vfstab and /etc/system (do this only for the root slice!): # metaroot d30 4. Create the swap slice mirror and its first submirror# metainit -f d11 1 1 c0t0d0s1 5. Create the var slice mirror and its first submirror# metainit -f d14 1 1 c0t0d0s4 6. Create the usr slice mirror and its first submirror# metainit -f d15 1 1 c0t0d0s5 7. Create the unassigned slice mirror and its first submirror# metainit -f d16 1 1 c0t0d0s6 8. Create the home slice mirror and its first submirror# metainit -f d17 1 1 c0t0d0s7 9. Edit /etc/vfstab to mount all mirrors after boot, including mirrored swap/etc/vfstab before changes: fd - /dev/fd fd - no - /etc/vfstab after changes:fd - /dev/fd fd - no - Notes: The entry for the root device (/) has already been altered by the metaroot command we executed before.
# lockfs -fa && init 6 11. Attach the second submirrors to all mirrors # metattach d30 d20 Notes: This will finally cause the data from the boot disk to be synchronized with the mirror drive. You can use metastat to track the mirroring progress.
# dumpadm -d `swap -l tail -1 awk '{print $1}' 13. Make the mirror disk bootable # installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk /dev/rdsk/c0t1d0s0 Notes: This will install a boot block to the second disk.
# ls -l /dev/dsk/c0t1d0s0 15. Create a device alias for the mirror disk # eeprom "nvramrc=devalias mirror /pci@1f,4000/scsi@3/disk@1,0" Add the mirror device alias to the Open Boot parameter boot-device to prepare the case of a problem with the primary boot device. # eeprom "boot-device=disk mirror cdrom net" You can also configure the device alias and boot-device list from the Open Boot Prompt (OBP a.k.a. ok prompt): ok nvalias mirror /pci@1f,4000/scsi@3/disk@1,0 Notes: From the OBP, you can use boot mirror to boot from the mirror disk. On my test system, I had to replace sd@1,0:a with disk@1,0. Use devalias on the OBP prompt to determine the correct device path. |
2 comments:
How to check the status of boot blk on mirror?
Hi,
Please help me How to check the status of boot blk on mirror?
Regards,
Sai
ksaikrishna7@gmail.com
Post a Comment