Operating System - Linux
1820879 Members
4954 Online
109628 Solutions
New Discussion юеВ

mdadm: /dev/hdb1 does not appear to be an md device -- plz help

 
SOLVED
Go to solution
Maaz
Valued Contributor

mdadm: /dev/hdb1 does not appear to be an md device -- plz help

Hello gurus

# fdisk -l /dev/hdb

Disk /dev/hdb: 8622 MB, 8622931968 bytes
255 heads, 63 sectors/track, 1048 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdb1 1 123 987966 fd Linux raid autodetect
# fdisk -l /dev/hdd

Disk /dev/hdd: 3249 MB, 3249340416 bytes
16 heads, 63 sectors/track, 6296 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

Device Boot Start End Blocks Id System
/dev/hdd1 1 1939 977224+ fd Linux raid autodetect
# mdadm --create --verbose --level=1 --raid-devices=2 /dev/hdb1 /dev/hdd1
mdadm: /dev/hdb1 does not appear to be an md device

Plz help
Regards
Maaz
3 REPLIES 3
Stuart Browne
Honored Contributor

Re: mdadm: /dev/hdb1 does not appear to be an md device -- plz help

For RAID, in particular RAID1, the two physical devices need to be of the same size.

By the looks of it, they are somewhat different in size.

The 'mdadm' manual states that it won't create if there is more than a 1% descrepancy.

It also mentions a '--run' argument which might be of use to you.

But start by checking the partition sizes..
One long-haired git at your service...
Sergejs Svitnevs
Honored Contributor
Solution

Re: mdadm: /dev/hdb1 does not appear to be an md device -- plz help

syntax is: mdadm --create /dev/md ...

To create next md device you should run:
mdadm --create /dev/md0 --level raid1 --raid-devices 2 /dev/hdb1 /dev/hdd1

Regards,
Sergejs
Maaz
Valued Contributor

Re: mdadm: /dev/hdb1 does not appear to be an md device -- plz help

Dear Stuart Browne and Sergejs Svitnevs Thanks a Million for help/reply.

Yes I forgot/skiped to write '/dev/md0'.

now correct syntax that works is:
mdadm --create --verbose /dev/md0 --level=1 --raid-devices=2 /dev/hdb1 /dev/hdd1

Thanks again
Regards
Maaz