On Tue Jun 02, 2009 at 02:00:15PM +0200, Alexander Rietsch wrote: >> >> AFAIK, the only solution at this stage is to recreate the array. >> >> You need to use the "--assume-clean" flag (or replace one of the drives >> with "missing"), along with _exactly_ the same parameters & drive order >> as when you originally created the array (you should be able to get most >> of this from mdadm -D). This will rewrite the RAID metadata, but leave >> the filesystem untouched. > > A glimpse of hope. Thank you! Didn't know about this --assume-clean flag. > So just to double-check: > > The array to create would be: > disc 0: sdi1 <- is now disc 7 and SPARE due to failed replacement operation > disc 1: sdl1 > disc 2: sdh1 > disc 3: sdj1 > disc 4: sdk1 > disc 5: sdg1 > disc 6: sda1 <- is now faulty removed > > So I just create an incomplete array without sda1 in the same order which > would be: > > mdadm --create /dev/md0 --assume-clean --level=5 --chunk=64 > --raid-devices=7 /dev/sdi1 /dev/sdl1 /dev/sdh1 /dev/sdj1 /dev/sdk1 > /dev/sdg1 > Almost - you'll also need to specify "missing" for disc 6 (and the --assume-clean isn't actually needed in this case, as the array can't do any reconstruction with a missing drive), so: mdadm --create /dev/md0 --level=5 --chunk=64 --raid-devices=7 /dev/sdi1 /dev/sdl1 /dev/sdh1 /dev/sdj1 /dev/sdk1 /dev/sdg1 missing > I'm not sure about the drive oder in the mdadm command: is it correct to > assume <drive 0> <drive 1> <drive 2> in order or is it mirrored like <drive > 2> <drive 1> <drive 0> ? > I also hope the command doesn't trigger any recovery actions or filesystem > changes.. This should be safe, yes - the numbers are also given in the output from "mdadm -D /dev/md0" or "mdadm -E /dev/sdl1". The array creation doesn't trigger any changes at all to the filesystem (though mounting it might, even in read-only mode) so is perfectly safe to do. You can also try "fsck -n" on the filesystem before mounting to verify that the array order is correct - this may fail on filesystems with unflushed journal data though. Cheers, Robin -- ___ ( ' } | Robin Hill <robin@xxxxxxxxxxxxxxx> | / / ) | Little Jim says .... | // !! | "He fallen in de water !!" |
Attachment:
pgpkwv5NoZnnA.pgp
Description: PGP signature