LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Mdadm RAID 5 degradated array not mountable. Metadata lost? (https://www.linuxquestions.org/questions/linux-hardware-18/mdadm-raid-5-degradated-array-not-mountable-metadata-lost-4175427899/)

^andrea^ 09-18-2012 05:12 PM

Mdadm RAID 5 degradated array not mountable. Metadata lost?
 
Hi All.

Let's see who remembers anything about mdadm... :-)

I HAD a fully functional RAID 5 mdadm array of 3 disks... HAD!!!
until one proved to be defective... (I'm still waiting for the replacement).

I kept the computer off most of the time (while awaiting for the replacement).

A little while ago though, while I was restarting it (with the 2 working disks ONLY), it failed to boot.
Now it doesn't boot at all as it cannot mount the main raid partition.

I believe the data on the two disks SHOULD still be fine but somehow mdadm seems to have lost the metadata and it doesn't know how to mount that array anymore...

I have to start the computer with Ubuntu Live CD and this is the output when I try to assemble the existing arrays:
root@ubuntu:~# mdadm --assemble --scan
mdadm: No suitable drives found for /dev/md1

Here is the output of "--examine" instead (mdadm --examine /dev/sdx3")

root@ubuntu:~# mdadm --examine /dev/sda3
/dev/sda3:
Magic : a92b4efc
Version : 00.90.00
UUID : 00000000:00000000:00000000:00000000
Creation Time : Mon Sep 17 16:25:30 2012
Raid Level : -unknown-
Raid Devices : 0
Total Devices : 2
Preferred Minor : 1

Update Time : Mon Sep 17 16:35:28 2012
State : active
Active Devices : 0
Working Devices : 2
Failed Devices : 0
Spare Devices : 2
Checksum : be36f1ae - correct
Events : 1


Number Major Minor RaidDevice State
this 0 8 19 0 spare /dev/sdb3

0 0 8 19 0 spare /dev/sdb3
1 1 8 3 1 spare /dev/sda3

---------------------------------------------------------------------

root@ubuntu:~# mdadm --examine /dev/sdb3
/dev/sdb3:
Magic : a92b4efc
Version : 00.90.00
UUID : 00000000:00000000:00000000:00000000
Creation Time : Mon Sep 17 16:25:30 2012
Raid Level : -unknown-
Raid Devices : 0
Total Devices : 2
Preferred Minor : 1

Update Time : Mon Sep 17 16:35:28 2012
State : active
Active Devices : 0
Working Devices : 2
Failed Devices : 0
Spare Devices : 2
Checksum : be36f1a0 - correct
Events : 1


Number Major Minor RaidDevice State
this 1 8 3 1 spare /dev/sda3

0 0 8 19 0 spare /dev/sdb3
1 1 8 3 1 spare /dev/sda3


Any idea on what happened and/or (most importantly) I should be doing?

Thanks in advance for any clue.

Andrea

PS: The system runs on Ubuntu 10.04 32 bit

eantoranz 09-19-2012 11:35 AM

I don't know what you will do to get it up and running but keep in mind you can go "the hard way" with raidpycovery.

http://www.freesoftwaremagazine.com/.../recovery_raid
https://code.launchpad.net/~eantoran...k/raidpycovery

^andrea^ 09-21-2012 02:14 PM

Hi,

Thanks eantoranz. Is that your software? :-)

I haven't found much information about it on the net, like a clear tutorial or something like that...
Anyway, my MDADM raid partition had several LVMs built on top, which I suppose it might make the whole thing even more complicated.
Is LVM supported by "raidpycovery"?


Regarding fixing my array, I thought that, since the data (afaik) seems to be there,
MAYBE recreating the array on top of the current one would tell mdadm how the array is supposed to work.
Considering I have sda3 and sdb3 left, I could run something something like:
mdadm --create --verbose /dev/md1 --level=5 --raid-devices=3 /dev/sda3 /dev/sdb3 missing

Does anyone know whether mdadm is smart enough to understand that there is already some data in the array
or it is simply going to wipe the whole thing?

As usual, any advice would be appreciated.

Cheers,
Andrea

eantoranz 09-21-2012 02:56 PM

Well.... I don't know how you will handle the upper layer stuff.... the lower layer "disk" will end up in a single image file (so you need a lot of room in order to rebuild the image of the disk). Check the readme included in the docs. There are examples on how to use it.

^andrea^ 09-23-2012 07:02 AM

Ok.

Thanks for your help eantoranz.

It's a pity noone else seem to have any idea on how to (at least try) restore the array... :-(

Andrea


All times are GMT -5. The time now is 05:30 AM.