<html><body><div style="color:#000; background-color:#fff; font-family:arial, helvetica, sans-serif;font-size:12pt"><div><span>It's been a while since I did this. A search on google gives http://www.tcpdump.com/kb/os/linux/removing-failed-raid-devices.html which seems right. <br></span></div><div><br></div><div>The commands (you will have to adjust it for your configuration) would be:</div><div><br></div><div>mdadm /dev/md0 --fail /dev/sdc1</div><div>This will fail the suspect drive (if not already).</div><div><br></div><div>mdadm /dev/md0 --remove /dev/sdc1</div><div>This will remove the drive from the array.</div><div><br></div><div>mdadm /dev/md0 --add /dev/sdc1</div><div>This adds the drive back into the array. It will then resync the failed drive. You can see this by doing cat /proc/mdstat:</div><div><br></div><div># cat /proc/mdstat<br>Personalities : [raid6] [raid5] [raid4]<br>md0 : active raid5 sdc1[1] sdb1[0] sdd1[2]<br>8385664
blocks level 5, 64k chunk, algorithm 2 [3/2] [U_U]<br>[=========>...........] recovery = 47.8% (2007428/4192832) finish=0.5min speed=62732K/sec<br><br>unused devices: <br><br></div><div> <br><br></div><div><span style="font-family:courier;">--- </span><br style="font-family:courier;"><span style="font-family:courier;">Wayne Johnson, | <span style="color:rgb(191, 95, 0);">There are two kinds of people: Those</span> </span><br style="font-family:courier;"><span style="font-family:courier;">3943 Penn Ave. N. | <span style="color:rgb(191, 95, 0);">who say to God, "Thy will be done," </span></span><br style="font-family:courier;"><span style="font-family:courier;">Minneapolis, MN 55412-1908 | <span style="color:rgb(191, 95, 0);">and those to whom God says, "All right, </span></span><br
style="font-family:courier;"><span style="font-family:courier;">(612) 522-7003 | <span style="color:rgb(191, 95, 0);">then, have it your way." --C.S. Lewis</span><br></span><br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; margin-top: 5px; padding-left: 5px;"> <div style="font-family: arial, helvetica, sans-serif; font-size: 12pt;"> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div dir="ltr"> <font face="Arial" size="2"> <hr size="1"> <b><span style="font-weight:bold;">From:</span></b> Mike Miller <mbmiller+l@gmail.com><br> <b><span style="font-weight: bold;">To:</span></b> Wayne Johnson <wdtj@yahoo.com>; TCLUG Mailing List <tclug-list@mn-linux.org> <br> <b><span style="font-weight: bold;">Sent:</span></b> Monday, April 2, 2012 10:38 AM<br> <b><span style="font-weight:
bold;">Subject:</span></b> Re: [tclug-list] fixing a RAID1 after drive failure<br> </font> </div> <br>
On Mon, 2 Apr 2012, Wayne Johnson wrote:<br><br>> On Mon, 2 Apr 2012, Mike Miller wrote:<br>> <br>>> Suppose one drive failed in my RAID1 mirrored pair. Can I then simply pull the bad drive, replace it with a good one (brand new), and have it work? Will it just automagically rebuild the RAID1 by mirroring onto the new drive?<br>>> <br>>> This is Ubuntu software RAID1.<br>> <br>> Actually, in my experience, the drive may not have a permement failue. You can re-activate the drive again, it will resync the failed drive, and you are running again. If it happens too frequently, replace the drive. <br><br>How do I reactivate a drive? That sounds like a great idea.<br><br>Mike<br><br> </div> </div> </blockquote></div> </div></body></html>