Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 02-03-2010, 07:40 AM   #1
LQ Newbie
Registered: Apr 2005
Location: Cambridge, UK
Distribution: Ubuntu 20.04
Posts: 19

Rep: Reputation: 1
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.
Old 02-04-2010, 01:18 AM   #2
Senior Member
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 344Reputation: 344Reputation: 344Reputation: 344
Use the '--readwrite' flag when adding the device to the array. See 'man mdadm'.
Old 02-06-2010, 01:52 AM   #3
LQ Newbie
Registered: Apr 2005
Location: Cambridge, UK
Distribution: Ubuntu 20.04
Posts: 19

Original Poster
Rep: Reputation: 1
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
Old 08-16-2016, 07:05 AM   #4
LQ Newbie
Registered: Aug 2016
Posts: 2

Rep: Reputation: Disabled
See echo -writemostly >/sys/block/...



mdadm, raid

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
mdadm: flag device as write-mostly on pre-existing array zazoo24601 Linux - General 1 08-15-2016 12:22 PM
mdadm raid1 both bootable chiendarret Linux - Server 1 03-09-2009 07:53 AM
Migrate to a raid1 with mdadm Ossar Linux - Software 2 08-19-2008 11:55 AM
Software RAID1 with mdadm bujecas Debian 0 10-26-2006 09:56 AM
raid1 using mdadm? help plz akadidm Linux - Hardware 3 06-09-2005 04:58 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:09 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration