View previous topic :: View next topic |
Author |
Message |
dirtbag Guru
Joined: 18 Feb 2003 Posts: 508 Location: NC
|
Posted: Fri Mar 15, 2013 8:51 pm Post subject: software raid got messed up.. [resolved] |
|
|
I upgraded my system and kernel last weekend and my md1 and md3 started showing up as
md126 and md127.. After freaking out and trying to "rebuild" them as md1 and md3, i finally figured out there was something else wrong with my system that wouldnt let it boot.
anyway, everything is booting fine now, but now I have somehow ended up with the following for my raid ..
Code: |
jason@beast ~ $ cat /proc/mdstat
Personalities : [raid0] [raid1]
md1 : active raid1 sdb1[1] sda1[0]
88256 blocks [2/2] [UU]
md127 : active raid1 sda3[0]
193310080 blocks [2/1] [U_]
md3 : active raid1 sdb3[1]
193310080 blocks [2/1] [_U]
unused devices: <none>
jason@beast ~ $ |
and im looking for advice on how to fix this.
md1 is /boot
md3 is /
mount says
/dev/md3 on / type ext3 (rw,noatime,errors=continue,barrier=1,data=ordered)
is it as simple as
http://www.howtoforge.com/replacing_hard_disks_in_a_raid1_array
I dont think that the disk is actually bad, i will probably remove it and fsck it and then re-add it back..
so im thinking something like the following:
Code: |
mdadm --manage /dev/md127 --fail /dev/sda3
mdadm --manage /dev/md127 --remove /dev/sda3
mdadm --manage /dev/md3 --add /dev/sda3
|
regards,
db
Last edited by dirtbag on Sat Mar 16, 2013 12:37 pm; edited 1 time in total |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54099 Location: 56N 3W
|
Posted: Fri Mar 15, 2013 10:13 pm Post subject: |
|
|
dirtbag,
Thats pretty much it. There are a few details.
As your raid is split, you probably want to keep the newest half and sync the oldest half to it.
Code: | mdadm -E /dev/sd[ab]3 | will help you determine which is the 'old' half.
The Code: | mdadm --manage /dev/md3 --add /dev/sda3 | may fail as mdadm will detect that /dev/sda3 (or whatever) is a member of a different raid set.
You may need to remove the raid superblock from it before you can use --add _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
dirtbag Guru
Joined: 18 Feb 2003 Posts: 508 Location: NC
|
Posted: Fri Mar 15, 2013 10:45 pm Post subject: |
|
|
thanks for the tip..
-db |
|
Back to top |
|
|
dirtbag Guru
Joined: 18 Feb 2003 Posts: 508 Location: NC
|
Posted: Sat Mar 16, 2013 12:36 pm Post subject: fixed.. whew.. |
|
|
jason@beast ~ $ cat /proc/mdstat
Personalities : [raid0] [raid1]
md1 : active raid1 sdb1[1] sda1[0]
88256 blocks [2/2] [UU]
md127 : active raid1 sdb3[1] sda3[0]
193310080 blocks [2/2] [UU]
unused devices: <none>
all I had to do was stop the md group and then add that disk to the other md group.
but when the server came up, i had to adjust the grub.conf to use 127 instead of 3
-db |
|
Back to top |
|
|
|