[mythtv-users] OT Help: mdadm segfault
scram69 at gmail.com
Sat Sep 22 06:47:21 UTC 2007
On 9/21/07, Steve MacLaren <scram69 at gmail.com> wrote:
> But it looks like I will just have to ignore the obvious contradictions
> and forge ahead trying to mount and access a 3-drive array by messing with
> /sys/block/md0/md/array_state, then wiping and re-adding the fourth drive...
Finally, some good news. Before I went ahead picking 3 disks at random and
assembling, I re-read through all of the posts on this thread. The one that
caught my eye was in f-myth's PPS:
"for each drive, try dd if=/dev/sdaN of=/dev/null bs=1M count=1000 and see
if you can read the first gig of the device"
I hadn't yet tried that, so I gave it a try. Sure enough, /dev/sdd1 cause a
reboot when I tried the read. Not being hardware-savvy enough to know which
of my physical drives was _actually_ /dev/sdd, I ran through a process of
elimination, removing power to one drive at a time until I could
successfully read from the three remaining drives.
Identifying the bad drive, I yanked it, replaced it with a brand new spare I
had fortuitously purchased some months ago, and restarted.
Upon restart, in dmesg, mdadm gave the same complaints about "dirty" drives
and the array status remained inactive. But I tried
mdadm -S /dev/md0
mdadm -Af /dev/md0 /dev/sda1 /dev/sdb1 /dev/sdc1
"mdadm: /dev/md0 has been started with 3 drives (out of 4)." - hey, that
sudo mdadm --detail /dev/md0
State : clean, degraded"
I don't feel so dirty anymore...
Pushing my luck,
sudo mount -t xfs /dev/md0 /var/lib/mythtv
and all of my data was back, seemingly intact!
So I did an fdisk on the new disk, formatting it as "linux raid autodetect",
steve at mediaserver:~$ sudo umount /dev/md0
steve at mediaserver:~$ sudo mdadm -a /dev/md0 /dev/sdd1mdadm: added /dev/sdd1
steve at mediaserver:~$ sudo mdadm --detail /dev/md0
Version : 00.90.03
Creation Time : Mon May 7 21:31:55 2007
Raid Level : raid5
Array Size : 1465151616 (1397.28 GiB 1500.32 GB)
Device Size : 488383872 (465.76 GiB 500.11 GB)
Raid Devices : 4
Total Devices : 4
Preferred Minor : 0
Persistence : Superblock is persistent
Update Time : Fri Sep 21 23:24:58 2007
State : clean, degraded, recovering
Active Devices : 3
Working Devices : 4
Failed Devices : 0
Spare Devices : 1
Layout : left-symmetric
Chunk Size : 128K
Rebuild Status : 0% complete
UUID : bc7a4d90:bd286a91:c109596b:d7e29b7e (local to host
Events : 0.174
Number Major Minor RaidDevice State
0 8 1 0 active sync /dev/sda1
1 8 17 1 active sync /dev/sdb1
2 8 33 2 active sync /dev/sdc1
4 8 49 3 spare rebuilding /dev/sdd1
Success! Thanks to everyone who helped me through this special hardware
Now I can finally get back to troubleshooting my "ivtv driver has stopped
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the mythtv-users