I have two slightly different 1 TB hard drives and I want to create a RAID1. I have spent last 5 hours trying to archive the same effect on virtual machine, because I want to test it out before playing with 500GB of data (but I also have a backup of this).
/dev/sda is drive with system
/dev/sdb is empty drive
I have done following:
dd if=/dev/sda of=/dev/sdb bs=32M
mdadm --create /dev/md0 -l raid1 -f -n 1 /dev/sdb1 mdadm --detail /dev/md0 | grep UUID
and then I add to /etc/mdadm/mdadm.conf:
ARRAY /dev/md0 metadata=1.2 uuid=dec18841:a77e61ec:898913cd:2bdbc71f
And I am stuck here. I found out that I need to boot from
/dev/md0 and add
/dev/sda1 to array but how can I boot from this array? And am I following good path of creating raid1 array?