Skip to contentSkip to conversation

raid5 on 2.4.21 and reconstruction problem

DISCUSSION Arkadiusz Miskiewicz 3 participants 4 messages Aug 13, 2003 – Aug 14, 2003 MD RAID

lore
Share & tools
lore
#0 lore raw

After patching 2.4.21 kernel md0 resync started as you said but now I have:

[root@perfo root]# mdadm -D /dev/md0
/dev/md0:

        Version : 00.90.00
  Creation Time : Tue May  4 09:37:53 1999
     Raid Level : raid5
     Array Size : 9960064 (9.50 GiB 10.20 GB)
    Device Size : 4980032 (4.75 GiB 5.10 GB)

Raid Devices : 3
Total Devices : 4
Preferred Minor : 0
Persistence : Superblock is persistent

Update Time : Wed Aug 13 12:24:12 2003
State : dirty, no-errors
Active Devices : 1
Working Devices : -1
Failed Devices : 4
Spare Devices : 1

Layout : left-symmetric
Chunk Size : 32K

Number Major Minor RaidDevice State
0 8 2 0 active sync /dev/sda2
1 8 18 1 faulty /dev/sdb2
2 0 0 2 faulty removed
3 8 34 3 spare /dev/sdc2
UUID : c6839323:6d5bd707:731f0c8c:10e7b89b
Events : 0.161

I've removed sdb2 and readded it as spare. Of course that didn't help.

Now ext3 reports failed IO, after reboot machine doesn't start (.mdadm: /dev/ md0 assembled from 1 drive and 2 spares - not enough to start the array).

I'm going to try ,,alternative method'' but I want to be sure of one thing - if I recreate array with the same parameters I wont loose any data on it?

ps. I'm not getting your mails directly (no idea why) and read them via google (that's why there is no references or in-reply-to in headers).

Signature · 6 lines
Arkadiusz Miśkiewicz    CS at FoE, Wroclaw University of Technology
[email protected]   AM2-6BONE, 1024/3DB19BBD, arekm(at)ircnet, PLD/Linux
-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
#1 lore raw
Quoted 32 lines · On Wednesday August 13, [email protected] wrote:

After patching 2.4.21 kernel md0 resync started as you said but now I have:

[root@perfo root]# mdadm -D /dev/md0
/dev/md0:

        Version : 00.90.00
  Creation Time : Tue May  4 09:37:53 1999
     Raid Level : raid5
     Array Size : 9960064 (9.50 GiB 10.20 GB)
    Device Size : 4980032 (4.75 GiB 5.10 GB)

Raid Devices : 3
Total Devices : 4
Preferred Minor : 0
Persistence : Superblock is persistent

Update Time : Wed Aug 13 12:24:12 2003
State : dirty, no-errors
Active Devices : 1
Working Devices : -1
Failed Devices : 4
Spare Devices : 1

Layout : left-symmetric
Chunk Size : 32K

Number Major Minor RaidDevice State
0 8 2 0 active sync /dev/sda2
1 8 18 1 faulty /dev/sdb2
2 0 0 2 faulty removed
3 8 34 3 spare /dev/sdc2
UUID : c6839323:6d5bd707:731f0c8c:10e7b89b
Events : 0.161

Quoted 2 lines

I've removed sdb2 and readded it as spare. Of course that didn't help.

Ouch. Looks like you had an error on /dev/sdb2. Is there anything about that in the logs?

Quoted 4 lines

I'm going to try ,,alternative method'' but I want to be sure of one thing - if I recreate array with the same parameters I wont loose any data on it?

This is correct. If you recreate the array with the same parameters you won't loose data. Be sure to only include the up-to-date drives in the array when you first create it. i.e. not /dev/sdc2.

NeilBrown

Quoted 7 lines

ps. I'm not getting your mails directly (no idea why) and read them via google (that's why there is no references or in-reply-to in headers).

Signature · 2 lines
Arkadiusz Miśkiewicz    CS at FoE, Wroclaw University of Technology
[email protected]   AM2-6BONE, 1024/3DB19BBD, arekm(at)ircnet, PLD/Linux

-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#2 lore raw
Quoted 8 lines
Quoted 8 lines

Number Major Minor RaidDevice State
0 8 2 0 active sync /dev/sda2
1 8 18 1 faulty /dev/sdb2
2 0 0 2 faulty removed
3 8 34 3 spare /dev/sdc2
UUID : c6839323:6d5bd707:731f0c8c:10e7b89b
Events : 0.161

Quoted 5 lines
Quoted 2 lines

I've removed sdb2 and readded it as spare. Of course that didn't help.

Ouch. Looks like you had an error on /dev/sdb2. Is there anything about that in the logs?

Error reported by md subsystem in kernel? Maybe I had (but that unlikely) - I'll check. Whole /dev/sdb device should be ok because I have part of /dev/md1 here, too (/dev/sdb3) and it's working fine.

Quoted 7 lines
Quoted 3 lines

I'm going to try ,,alternative method'' but I want to be sure of one thing - if I recreate array with the same parameters I wont loose any data on it?

This is correct. If you recreate the array with the same parameters you won't loose data. Be sure to only include the up-to-date drives in the array when you first create it. i.e. not /dev/sdc2.

I did that. Added /dev/sdc2 as missing but that didn't help. At beginning mdadm reported that /dev/sda2 and /dev/sdb2 are in sync, that here is another driver which failed. After adding /dev/sdc2 as spare is started resync but after finishing resyncing mdadm reported that both /dev/sdb2 and /dev/sdc2 are failed :-( Tried that three times - always after getting into sync two drives was reported as failed.

So I recreated array with the same parameters but didn't add /dev/sdc2 as spare, copied all data and tried to create array from beginning using all these devices. Unfortunately after mdadm -C... it said that devices looks like from some array so I confirmed but... new array had /dev/sdc2 as failed :(

Why failed? - did it read that information from old superblock? If yes then I have feature request: avility to mdadm to erease old superblocks from cmdline.

No idea where that superblock resides on disk so I've tried to dd if=/dev/zero each /dev/sdX2 partition but that didn't help since I've dded only beginning of each partition and it seems that superblock is somewhere at end.

After creating raid1, mirror and few other types of raid on these /dev/sdX2 partitions and then creating raid5 again I finally got working raid5 array where each disk is active sync! Hurray :)

Thanks for help!

Quoted 1 line

NeilBrown

#3 lore raw
Quoted 1 line · Arkadiusz Miskiewicz

I'll check. Whole /dev/sdb device should be ok because I have part of

Not necessarily. You could be getting sector read/write errors on one part of the disk while the rest of the disk is fine...

Quoted 4 lines

/dev/md1 here, too (/dev/sdb3) and it's working fine.

Why failed? - did it read that information from old superblock?

Yes, if there was a superblock there, it would have read it.

Quoted 3 lines

If yes then I
have feature request: avility to mdadm to erease old superblocks from cmdline.

This feature already exists. Try mdadm --zero-superblock <dev>.

--
Paul