View previous topic :: View next topic |
Author |
Message |
burlie n00b
Joined: 06 Sep 2004 Posts: 14
|
Posted: Sun Aug 21, 2005 9:55 pm Post subject: Software RAID on / - Unable to stop array on shutdown |
|
|
I am running software RAID 1 on /boot and / and software RAID 5 on /home. The /boot and /home filesystems unmount cleanly and their respective RAID arrays are stopped cleanly on a shutdown. The / filesystem's RAID array (/dev/md2) however, does not stop when an /sbin/shutdown -h or /sbin/shutdown -r is issued. Is this a known issue or is this misconfiguration on my part? What can be done to allow / to umount and stop cleanly?
Thanks for any and all help. |
|
Back to top |
|
|
widan Veteran
Joined: 07 Jun 2005 Posts: 1512 Location: Paris, France
|
Posted: Mon Aug 22, 2005 1:09 am Post subject: |
|
|
mdadm will never be able to shutdown the array on which / resides, as it is still in use (at least by mdadm itself, and also by other things like the shell running the init scripts, /sbin/init itself, ...). But the array will still be shutdown correctly by the kernel, as the md driver has a "reboot notifier" (a function called by the kernel before rebooting / shutting down) that stops all the arrays that are still active at that time. So your / array is safe.
Actually it's possible to run a system with software RAID without even having mdadm or raidtools on the system, as long as you have the arrays set up to be autodetected by the kernel at boot (partition type 0xfd) and the md driver built-in (it won't do the autodetect if built as a module). Of course it's not really something you want to do, but it works. |
|
Back to top |
|
|
burlie n00b
Joined: 06 Sep 2004 Posts: 14
|
Posted: Mon Aug 22, 2005 1:18 am Post subject: |
|
|
Awesome, thanks! Perhaps on shutdown an error shouldn't be thrown for this because it is always going to happen then? |
|
Back to top |
|
|
widan Veteran
Joined: 07 Jun 2005 Posts: 1512 Location: Paris, France
|
Posted: Mon Aug 22, 2005 1:22 am Post subject: |
|
|
There was a similar problem with root on LVM. The init script for LVM got fixed for that. Maybe they will fix the one for mdadm. |
|
Back to top |
|
|
|