Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm building a raid1 (ok it will probably be a raid10,f2 but the difference with 2 drives... isn't much) system with 2 1TB drives. However, 1 of the drives I've ordered is bad so I'm RMA-ing it. I'm wondering if I could partition and install to the 1 drive and then rebuild the array when I get the second drive (after I test it of course) My initial investigation doesn't show me a way of creating the array without specifying all devices... and the device the second drive will be is one that has data that I will need to migrate (plus it's not big enough). Is it possible that I could create an array without specifying all devices? or specify false ones and reconfigure to the right ones later? Or some other method I'm not thinking of.

share|improve this question
add comment

1 Answer

up vote 3 down vote accepted

mdadm will let you create a new array with a missing device. Name the drive / partition as "missing" in the mdadm command line, like, say:

mdadm --create /dev/md0 --level=raid1 --raid-devices=2 /dev/sda1 missing

You can add the second drive to the array when you get it back:

mdadm --manage /dev/md0 --add /dev/sdb1

Given that you've had one of these drives fail already I'd question the wisdom in using the other drive until you've got the first one back from RMA.

share|improve this answer
    
I been testing this drive with badblocks and smartctl for about a week. the other drive was definitely DOA it found badblocks in maybe an hour or so. besides I'm going to make sure my data is backed up. This old drive isn't going anywhere. I'll try these commands thanks. –  xenoterracide May 14 '10 at 1:07
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.