mdadm: Cannot open /dev/sdc1: Device or resource busy

Das anlegen eines Raid5 schlug bei mir fehl.

Komisch erschien mir das schon beim anlegen der Partition. Das lieferte mir folgende Waring:
WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.

Das anlegen schlug dadurch fehl:
#mdadm --create --verbose /dev/md0 --level=5 --raid-devices=3 /dev/sdb1 /dev/sdc1 /dev/sdd1
mdadm: layout defaults to left-symmetric
mdadm: chunk size defaults to 64K
mdadm: Cannot open /dev/sdc1: Device or resource busy
mdadm: Cannot open /dev/sdd1: Device or resource busy
mdadm: create aborted

Mir einem blick in mdstat war klar das da was schief läuft.
#cat /proc/mdstat
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md5 : inactive sdc1[1](S) sdd1[2](S)
488391808 blocks

unused devices:

Abhilfe hat da das stoppen des eigentlich nicht vorhandenem Raid gebracht:
#mdadm --manage --stop /dev/md5
mdadm: stopped /dev/md5

Dann konnte ich ohne problem das Raid anlegen:
#mdadm --create --verbose /dev/md0 --level=5 --raid-devices=3 /dev/sdb1 /dev/sdc1 /dev/sdd1
mdadm: layout defaults to left-symmetric
mdadm: chunk size defaults to 64K
mdadm: /dev/sdc1 appears to be part of a raid array:
level=raid5 devices=3 ctime=Fri Jul 10 18:08:56 2009
mdadm: /dev/sdd1 appears to be part of a raid array:
level=raid5 devices=3 ctime=Fri Jul 10 18:08:56 2009
mdadm: size set to 244195904K
Continue creating array?
Continue creating array? (y/n) y
mdadm: array /dev/md0 started.

# cat /proc/mdstat
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md0 : active raid5 sdd1[3] sdc1[1] sdb1[0]
488391808 blocks level 5, 64k chunk, algorithm 2 [3/2] [UU_]
[>....................] recovery = 1.6% (4089472/244195904) finish=114.4min speed=34948K/sec

unused devices:

Tags: