Linear RAID recovery

Discussion in 'Technical' started by anoneironaut, Jan 24, 2010.

  1. anoneironaut

    anoneironaut New Member

    Hey all,

    I've got a Linux box set up with two RAID-1 partitions and a Linear RAID partition for storage. If one of the drives fails its pretty simple to repair RAID-1 and reassemble. However for Linear is it possible to just kill the linear RAID array .. reformat the two partitions that used to make it up and recreate the array? I've tried to unmount the device and do all of this but it comes up as busy. Can anyone help?

    -Anon
     
  2. anoneironaut

    anoneironaut New Member

    More information

    More info. I'm running on RHEL4. I was really just asking if anyone else had done this and what steps they did. Kernel is 2.6.22. Here is what I tried to do:

    bash# mdadm --manage /dev/md1 -f /dev/sda2
    mdadm: set /dev/sda2 faulty in /dev/md1
    bash# mdadm --manage /dev/md1 -f /dev/sdb2
    mdadm: set /dev/sdb2 faulty in /dev/md1
    bash# cat /proc/mdstat
    Personalities : [linear] [raid1]
    md1 : active linear sdb2[1] sda2[0]
    957216768 blocks 64k rounding

    md0 : active raid1 sdb1[1]
    9775424 blocks [2/1] [_U]

    unused devices: <none>
    bash# mdadm --manage /dev/md1 -r /dev/sdb2
    mdadm: hot remove failed for /dev/sdb2: Device or resource busy
    bash# mdadm --manage /dev/md1 -r /dev/sda2
    mdadm: hot remove failed for /dev/sda2: Device or resource busy
    bash# mdadm --manage /dev/md1 -fr /dev/sda2
    mdadm: hot remove failed for /dev/sda2: Device or resource busy
    bash# mdadm --manage --stop /dev/md1
    mdadm: fail to stop array /dev/md1: Device or resource busy
    bash# fuser -m /dev/md1
    bash# fuser -m /dev/sda2
    bash# fuser -m /dev/sdb2
    bash# mdadm --manage --stop /dev/md1
    mdadm: fail to stop array /dev/md1: Device or resource busy
    bash-2.05b# lsof | grep md1
    bash-2.05b#

    If anyone has successfully restored a linear RAID(i.e. formatted both normal devices and created the array). Please help :).

    -Anon
     
  3. falko

    falko Super Moderator Howtoforge Staff

  4. anoneironaut

    anoneironaut New Member

    I'm NOT having problems with RAID-1 arrays. Like I said up top.. I want to take a failed LINEAR RAID array. Stop it. Format the two partitions that make it up. And then recreate the LINEAR RAID array. But I am unable to do this and I'm wondering if it is possible.
     
  5. raid recovery

    raid recovery New Member

    Hi Anon,

    If you need any further help, the company RAID-Recovery-Online.com can achieve RAID 1 recovery remotely.

    Goodluck.
     
  6. Neo

    Neo New Member

    That's a very good resolution! Thanks!
     

Share This Page