1

a friend of mine had an RAID 0 Array of two 500GB HDDs (Windows - NTFS - Dell preinstalled) and one seems to have an bad sector. So i started the PC from Ubuntu Live Disk (15.04) and tried to assemble the array with mdadm to rescue data (cos from windows it always breaks).

There are 3 Partitions over the Raid:

  • first on /dev/sda Windows Boot [100MB]
  • second i guess is a Dell Recovery Partition [100GB])
  • and the third over /dev/sda and /dev/sdb (around 850GB together, should be an NTFS Partition Windows C:\)

And again everything listed:

    $ sudo mdadm --examine /dev/sda
    /dev/sda:
          Magic : Intel Raid ISM Cfg Sig.
        Version : 1.0.00
        Orig Family : f3069b3e
         Family : f3069b3e
         Generation : 00006a1b
         Attributes : All supported
           UUID : b0ad0525:0ddce192:803168da:22a1ffe4
           Checksum : c280a1b0 correct
        MPB Sectors : 1
          Disks : 2
       RAID Devices : 1

    [ARRAY0]:
           UUID : 69bc365d:4feceb32:e1d6c70a:c5d22a9a
         RAID Level : 0
        Members : 2
          Slots : [__]
        Failed disk : 1
          This Slot : ?
         Array Size : 1953536000 (931.52 GiB 1000.21 GB)
       Per Dev Size : 976768264 (465.76 GiB 500.11 GB)
      Sector Offset : 0
        Num Stripes : 3815500
         Chunk Size : 128 KiB
           Reserved : 0
      Migrate State : idle
          Map State : normal
        Dirty State : clean

      Disk00 Serial : 5QM21AYL
          State : active failed
             Id : 00000000
        Usable Size : 976766862 (465.76 GiB 500.10 GB)

      Disk01 Serial : 5QM220MP
          State : active failed
             Id : 00010000
        Usable Size : 976766862 (465.76 GiB 500.10 GB)

I'm not this firm with RST and mdadm so i googled and tried:

    $ sudo mdadm --assemble /dev/md0 /dev/sda /dev/sdb --force
    mdadm: Marking array /dev/md0 as 'clean'
    mdadm: Container /dev/md0 has been assembled with 2 drives

and then:

    $ sudo mount -t ntfs /dev/md0 /home/olddata/
    Failed to read bootsector (size=0)
    Failed to sync device /dev/md0: Input/output error
    Failed to mount '/dev/md0': Invalid argument
    The device '/dev/md0' doesn't seem to have a valid NTFS.
    Maybe the wrong device is used? Or the whole disk instead of a
    partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?

Can anyone explain to me what is wrong with my definition and guide me on the right path?

Edit:

additional information:

    $ sudo fdisk -l

    Disk /dev/loop0: 1 GiB, 1101672448 bytes, 2151704 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk /dev/sda: 465,8 GiB, 500107862016 bytes, 976773168 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: dos
    Disk identifier: 0xc8000000

    Device     Boot     Start        End    Sectors   Size Id Type
    /dev/sda1  *         2048     206847     204800   100M  7 HPFS/NTFS/exFAT
    /dev/sda2          206848  245762047  245555200 117,1G  7 HPFS/NTFS/exFAT
    /dev/sda3       245762048 1953531903 1707769856 814,3G  7 HPFS/NTFS/exFAT

    Disk /dev/sdb: 465,8 GiB, 500107862016 bytes, 976773168 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes

Edit 2:

@psusi: So if i understood the things you said the assemble command over the devices is the right way to start:

    $ sudo mdadm --assemble /dev/md0 /dev/sda /dev/sdb --force
    mdadm: Marking array /dev/md0 as 'clean'
    mdadm: Container /dev/md0 has been assembled with 2 drives

But where to go from here?

    $ cat /proc/mdstat
    Personalities : [raid0] 
    md0 : inactive sda[1](S) sdb[0](S)
          6306 blocks super external:imsm

    unused devices: <none>

    $ lsblk
    NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
    sda      8:0    0 465,8G  0 disk 
    ├─sda1   8:1    0   100M  0 part 
    ├─sda2   8:2    0 117,1G  0 part 
    └─sda3   8:3    0 348,6G  0 part 
    sdb      8:16   0 465,8G  0 disk 
    sr0     11:0    1   1,1G  0 rom  /cdrom
    loop0    7:0    0     1G  1 loop /rofs

1 Answer 1

0

First, it is the array that is partitioned, not the individual drives. You must not attempt to access any partitions that may appear to be on the individual drives. Instead you mount the correct partition on the raid device. Further, intel fakeraid assembles the drives into a "container" which is then subdivided into individual raid arrays. It appears you have activated the container and I believe that automatically activates any other arrays it contains, but they are something other than /dev/md0. cat /proc/mdstat to see what arrays are active, or you might consult lsblk and it is one of the other arrays ( or partition on that array, such as /dev/md1p1 ) that should contain the filesystem you want to mount.

6
  • I edited my question and added more information.
    – Da Maex
    Jun 1, 2015 at 23:56
  • @DaMaex, ahh, it isn't activating the member array ( named ARRAY0 ) because it is marked as failed. Try mdadm --assemble -N ARRAY0 /dev/md0 /dev/md1 -f
    – psusi
    Jun 2, 2015 at 13:03
  • I tried $ sudo mdadm --assemble -N ARRAY0 /dev/md0 /dev/md1 -f which gives me: mdadm: cannot open device /dev/md1: No such file or directory Then i thought, maybe this way: $ sudo mdadm --assemble -N ARRAY0 /dev/sda /dev/sdb -f but aswell: mdadm: device /dev/sda exists but is not an md array. Do i have to activate md0 and md1 first, somehow?
    – Da Maex
    Jun 2, 2015 at 19:05
  • @DaMaex, oops... I got that backwards.. it is /dev/md1 then /dev/md0.. the idea is that you want to activate a new array ( md1 ) using md0 as the sole component, which is already a container of the actual disk drives.
    – psusi
    Jun 2, 2015 at 23:50
  • it gives me: md1 : inactive super external:/md0/0
    – Da Maex
    Jun 3, 2015 at 21:10

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .