RE: [opensuse] possible raid failure?
Hi James, On Wed, 04 Feb 2009, 19:35:36 +0100, James D. Parra wrote:
[...] Anyway to mark the sector as bad and restart the raid?
you should *immediately* run an intensive check on the drive; as root, run "smartctl -t long /dev/sda" which will last several minutes to hours depending on the size of the drive. Once it's finished you can see the results by running "smartctl -a /dev/sda" which may also show the LBA address of the failing block(s); there are some references (use Google) explaining what to do to mark (and remap) the sector.
This is a single drive mirrored (RAID1) and when the raid failed the system froze. I don't want that to happen again. What can I do to ensure that the system can ride through a RAID failure and how can I have the md send me an e-mail notifying me of the failure.
That's pretty easy, just run "insserv /etc/init.d/mdadm" and ensure that any e-mail sent to "root@localhost" will be delivered to some account who's actually looking at that e-mail.
After a reboot mdstat shows;
# cat /proc/mdstat Personalities : [raid1] [raid0] [raid5] [raid4] [linear] md0 : active raid1 sda1[0] sdb1[1] 160512 blocks [2/2] [UU]
md1 : active raid1 sdb2[1] 292872896 blocks [2/1] [_U] <snip>
I don't see sda2 on md1 so I guess its no longer mirrored. Any way to reactivate it while the raid is still up?
I'd not (yet) re-add it to the raid, better check the drive first as I wrote above. Afterwards you can re-add it using "mdadm /dev/md1 /dev/sda2". ~~~~~~~~~~~~~~~ Thank you for the details. Can I run "smartct" with the other RAID, md0 (sda1, sdb1) still running? Best regards, James -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
James D. Parra wrote:
Can I run "smartct" with the other RAID, md0 (sda1, sdb1) still running?
Yes, the internal selftest will not affect it. I run the short selftest on all IDE drives every day, and the long test once a week. -- Per Jessen, Zürich (1.62°C) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (2)
-
James D. Parra
-
Per Jessen