LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   How do I remove --write-mostly flag from linux mdadm raid1? (FC12) (http://www.linuxquestions.org/questions/linux-software-2/how-do-i-remove-write-mostly-flag-from-linux-mdadm-raid1-fc12-786661/)

adrian_stephens 02-03-2010 07:40 AM

How do I remove --write-mostly flag from linux mdadm raid1? (FC12)
 
FC12 i686 running on Core 2 processor.
2 1TB SATA disks attached, each split into identical partitions
(boot, root, spare-root, lvm). Each partition is mirrored raid1
using mdadm.

I had set one of my disks (sdb) raid characteristics to --write-mostly.
(in a failed attempt to get it to spin down and reduce noise/heat).
Disk sda has gone bad in situ, but works when I move it out to an external USB2 disk enclosure.

So each of my md devices has the old sdb marked write-mostly, and the old sda connected by usb. This should direct most read accesses to the slower device.

I'd like to remove the --write-mostly flag.

Is there any way to do this short of re-initializing the partion and copying. I don't want to do this for two reasons: 1. Slow to copy 1TB, 2. I don't want to entrust my only copy of data to my suspect old sda.

Thanks for any help / hints.

Adrian Stephens, Cambridge UK.

macemoneta 02-04-2010 01:18 AM

Use the '--readwrite' flag when adding the device to the array. See 'man mdadm'.

adrian_stephens 02-06-2010 01:52 AM

Hmm. Thanks for the response, but I don't think you're right. The --readwrite flag applies to the array. The --write-mostly flag applies to a component of that array. -- Adrian


All times are GMT -5. The time now is 03:22 AM.