7
2
Unfortunately the mdadm
and mdadm.conf
man pages are not quite up to par. I would like to enable the --write-mostly
flag for my RAID, but neither the man pages nor the internet will tell me how. I am not aware of any place to put default arguments for mdadm
, nor aware of when it would be launched and by what.
It seems the logical place to add this information is mdadm.conf
, but the flag is unmentioned in man mdadm.conf
. Where and how can I enable --write-mostly
? Thank you.
1I find it strange how the sysfs input parameter is "writemostly", sysfs state file output is "write_mostly", and mdadm command line parameter is "write-mostly". Why so little consistency here I wonder. – lkraav – 2014-11-30T19:23:39.380
On my system, it looks like the path would instead be
/sys/block/md0/md/dev-sda1/state
(note the additional/md
betweenmd0
anddev-sda1
), but I'm also using an older version. – rob – 2012-06-21T20:48:51.647I just tried this with both mdadm v2.6.3 and v3.2.3, and typing the command as @NeilBrown originally wrote it produces a "No such file or directory" error. Typing the command as I wrote it in my previous comment works as long as you are logged in as root. I've edited the answer to reflect the correct path. – rob – 2012-06-22T21:27:46.807
Hmm, it seems the writemostly property is not persistent when set using this method. After a reboot, the property disappeared. – rob – 2012-06-22T21:34:30.887