Here's how we do it. (/dev/sda is healthy disk)
For MBR Disks:
# sfdisk -d /dev/sda | sfdisk /dev/sdb
also can do a partitions rescan:
# sfdisk -R /dev/sdb
For GPT Disks:
WARNING: /dev/sdb is the DESTINATION! /dev/sda is SOURCE.
# sgdisk -R /dev/sdb /dev/sda
then set new UUIDs
# sgdisk -G /dev/sdb
then check if partitions have appeared:
# fdisk -l /dev/sdb
after that simply add your partitions:
# mdadm /dev/md0 -a /dev/sdb1
....add all md dev-disk pair...
then you can watch it syncing:
# watch cat /proc/mdstat
afterwards don't forget to install grub:
# grub-install /dev/sdb
TrackbacksTrackback specific URI for this entry
This link is not meant to be clicked. It contains the trackback URI for this entry. You can use this URI to send ping- & trackbacks from your own blog to this entry. To copy the link, right click and select "Copy Shortcut" in Internet Explorer or "Copy Link Location" in Mozilla.