Showing posts with label inactive raid. Show all posts
Showing posts with label inactive raid. Show all posts

Wednesday, May 8, 2013

How to get an inactive RAID device working again?

Problem:

After booting, my RAID1 device (/dev/md_d0 *) sometimes goes in some funny state and I cannot mount it

# mount /opt
mount: wrong fs type, bad option, bad superblock on /dev/md_d0,
       missing codepage or helper program, or other error
       (could this be the IDE device where you in fact use
       ide-scsi so that sr0 or sda or so is needed?)
       In some cases useful info is found in syslog - try
       dmesg | tail  or so


The RAID device appears to be inactive somehow:
# cat /proc/mdstat
Personalities : [linear]  [multipath]  [raid0]  [raid1]  [raid6]  [raid5]
                [raid4] [raid10]
md_d0 :  inactive sda4 [0] (S)
               241095104 blocks


# mdadm --detail /dev/md_d0
mdadm: md device /dev/md_d0 does not appear to be active.



Resolution:

run,

#mdadm --examine --scan >> /etc/mdadm/mdadm.conf
reboot the machine and you will found /dev/md0 will be active if you run

#cat /proc/mdstat