-   Linux - Newbie (
-   -   Why can't I create a RAID array? (

fireball1974 08-04-2012 07:04 PM

Why can't I create a RAID array?
I am trying to create a Linux software RAID array on Debian Squeeze. First I created the following partitions:


Both are formatted as FD (Linux RAID autodetect).
Now I try using mdadm to create a level-1 RAID array:

# mdadm --verbose --create /dev/md2 --level=1 --raid-devices=2 /dev/sdc2 /dev/sdd2

I get the following error messages:

mdadm: super1.x cannot open /dev/sdc2: No such file or directory
mdadm: ddf: Cannot open /dev/sdc2: No such file or directory
mdadm: Cannot open /dev/sdc2: No such file or directory
mdadm: device /dev/sdc2 not suitable for any style of array

What am I doing wrong?

btmiller 08-04-2012 10:06 PM

The error message seems straightforward -- /dev/sdc2 doesn't seem to exist. Have you checked in /dev to see if it, in fact, there? Depending on the partitioning tool you used and your hardware, you may need to reboot the machine to see newly created partitions.

frankbell 08-04-2012 10:07 PM

I've never done this, but, judging by the Debian wiki, you might have missed a step in creating the partitions:

fireball1974 08-05-2012 10:09 PM

I am not sure why, but this problem disappeared after I rebooted. Thank you for your suggestions!

chrism01 08-06-2012 08:31 PM

If you go into eg fdisk & create partitions, even when using 'w' to write the new partition table, sometimes the kernel won't see it until after a reboot.
One trick is to run the cmd partprobe after using 'w' & exiting fdisk

fireball1974 08-07-2012 12:54 AM

Thank you! That will help me in the future.

BTW, the tool I used to create the partitions was cfdisk.

chrism01 08-07-2012 01:01 AM

Never used it, but after 'saving changes' however cfdisk does it, exit and try partprobe anyway, then list the partitions however you want, or

cat /proc/partitions

All times are GMT -5. The time now is 12:25 PM.