Find the answer to your Linux question:
Results 1 to 5 of 5
Hi, I am trying to assemble a partially-grown RAID5 array (I interrupted the growing process on purpose, to ensure I can recover data if something interrupts growing the array on ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined! phosphide's Avatar
    Join Date
    Oct 2007
    Location
    Kalisz, Poland
    Posts
    5

    mdadm, assembling array after interrupt during growing


    Hi,

    I am trying to assemble a partially-grown RAID5 array (I interrupted the growing process on purpose, to ensure I can recover data if something interrupts growing the array on which I keep my real data).

    The OS is Fedora 10. The array was created using anaconda, during the installation. It consisted of sda2, sdb2, sdc2. /boot is on /dev/sda1 and sd[bcd]1 don't matter.
    Code:
    [root@f10-raid ~]# cat /etc/mdadm.conf
    # mdadm.conf written out by anaconda
    DEVICE partitions
    MAILADDR root
    
    ARRAY /dev/md0 level=raid5 num-devices=3 metadata=0.90 spares=1 UUID=7ba24636:261b5ba5:d6f453eb:dfc5afa4
    [root@f10-raid ~]# mdadm --detail /dev/md0
    /dev/md0:
            Version : 0.90
      Creation Time : Sun Dec 14 15:01:47 2008
         Raid Level : raid5
         Array Size : 8176640 (7.80 GiB 8.37 GB)
      Used Dev Size : 4088320 (3.90 GiB 4.19 GB)
       Raid Devices : 3
      Total Devices : 3
    Preferred Minor : 0
        Persistence : Superblock is persistent
    
        Update Time : Tue Dec 16 21:54:43 2008
              State : clean
     Active Devices : 3
    Working Devices : 3
     Failed Devices : 0
      Spare Devices : 0
    
             Layout : left-symmetric
         Chunk Size : 256K
    
               UUID : 7ba24636:261b5ba5:d6f453eb:dfc5afa4
             Events : 0.880
    
        Number   Major   Minor   RaidDevice State
           0       8        2        0      active sync   /dev/sda2
           1       8       18        1      active sync   /dev/sdb2
           2       8       34        2      active sync   /dev/sdc2
    md0 was physical volume of VolGroup00 and VolGroup00 included LogVolume00 and LogVolume01 (/root and swap).

    It worked perfectly, then I added sdd2 to md0 and started growing it:
    Code:
    mdadm --add /dev/md0 /dev/sdf1
    mdadm --grow /dev/md0 --raid-devices=4
    When it was a few per cent complete, I powered down the machine. After that, it didn't boot, saying
    Code:
    mdadm: no devices found for /dev/md0
      Reading all physical volumes.  This may take a while...
      Volume group "VolGroup00" not found
    Unable to access resume device /dev/VolGroup00/LogVol01
    mount: error mounting /dev/root on /sysroot as ext3: No such file or directory
    I booted with Fedora DVD into rescue mode, copied the original mdadm.conf to /etc/mdadm.conf and here is what I tried:
    Code:
    # mdadm --assemble /dev/md0
    mdadm: no devices found for /dev/md0
    # mdadm --assemble /dev/md0 /dev/sda2 /dev/sdb2 /dev/sdc2 /dev/sdd2
    mdadm: no devices found for /dev/md0
    # mdadm --examine /dev/md0
    mdadm: No md superblock detected on /dev/md0
    # mdadm --examine /dev/sda2        #the same for sdb2/sdc2/sdd2
    /dev/sda2:
              Magic : a92b4efc
            Version : 0.91.00
               UUID : 7ba24636:261b5ba5:d6f453eb:dfc5afa4
      Creation Time : Sun Dec 14 14:01:47 2008
         Raid Level : raid5
      Used Dev Size : 4088320 (3.90 GiB 4.19 GB)
         Array Size : 12264960 (11.70 GiB 12.56 GB)
       Raid Devices : 4
      Total Devices : 4
    Preferred Minor : 0
    
      Reshape pos'n : 123648 (120.77 MiB 126.62 MB)
      Delta Devices : 1 (3->4)
    
        Update Time : Tue Dec 16 21:02:24 2008
              State : active
     Active Devices : 4
    Working Devices : 4
     Failed Devices : 0
      Spare Devices : 0
           Checksum : 947a4a69 - correct
             Events : 927
    
             Layout : left-symmetric
         Chunk Size : 256K
    
          Number   Major   Minor   RaidDevice State
    this     0       8        2        0      active sync   /dev/sda2
    
       0     0       8        2        0      active sync   /dev/sda2
       1     1       8       18        1      active sync   /dev/sdb2
       2     2       8       34        2      active sync   /dev/sdc2
       3     3       8       50        3      active sync   /dev/sdd2
    # mdadm --grow --raid-disks=4 /dev/md0
    mdadm: /dev/md0 is not an active md array - aborting
    I see it's aware there was a reshape process in progress, but I don't know how to continue it.

    Any ideas?

    phosphide

  2. #2
    Just Joined!
    Join Date
    Apr 2009
    Posts
    1
    how did you get on ... I have a similar problem

  3. #3
    Just Joined! phosphide's Avatar
    Join Date
    Oct 2007
    Location
    Kalisz, Poland
    Posts
    5
    Unfortunately, I didn't
    I'm still using RAID0 with some backups and I'm afraid of moving to an array I can't rely on (because I have no idea how to fix it when something goes wrong).

  4. $spacer_open
    $spacer_close
  5. #4
    Just Joined!
    Join Date
    Jan 2010
    Posts
    1
    Quote Originally Posted by phosphide View Post
    # mdadm --assemble /dev/md0 /dev/sda2 /dev/sdb2 /dev/sdc2 /dev/sdd2
    Perhaps it would have worked better if you tried to assemble it with the same devices you created it from.... such as:

    # mdadm --assemble /dev/md0 /dev/sda2 /dev/sdb2 /dev/sdc2 /dev/sdf1

    or was that a typo in your --add line?

    You could also try adding the parameter -R

  6. #5
    Just Joined! phosphide's Avatar
    Join Date
    Oct 2007
    Location
    Kalisz, Poland
    Posts
    5
    It's over one year old, but I guess it's indeed a typo in the --add line (it typed some of the commands here manually, not copied it from terminal).

    I moved to another city and only have a laptop here, so setting up RAID doesn't have much sense other than for testing purposes, but still I'd like to try RAID again when I have some free time.

    Anyway, thanks for the answer!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •