On 13:41, John Robinson wrote: > >Normal shutdown should put the raid in read-only mode as last step. At > >least Debian does that. That way even a mounted raid will be clean > >after reboot. > > Yes, I would have thought it should as well. But I've just looked at > CentOS 5's /etc/rc.d/halt and as far as I can see it doesn't try to > switch md devices to read-only. There's no need to do that in the shutdown script as the kernel will switch all arrays to read-only mode on halt/reboot. Moreover, as raid arrays are automatically marked clean if no writes are pending for some small time period, a simple "sync; sleep 1" at the end of the shutdown script is usually enough to have a clean array during the next boot. An alternative way to deal with this issue is to not have a root file system at all but to mount/link each top level directory separately. This allows to stop all md arrays cleany. Andre -- The only person who always got his work done by Friday was Robinson Crusoe
Attachment:
signature.asc
Description: Digital signature