On Tue, Jan 29, 2019 at 11:48 AM Alan Mackenzie <a...@muc.de> wrote: > > On Tue, Jan 29, 2019 at 09:32:19 -0700, Grant Taylor wrote: > > On 01/29/2019 09:08 AM, Peter Humphrey wrote: > > > I'd rather not have to create an initramfs if I can avoid it. Would it > > > be sensible to start the raid volume by putting an mdadm --assemble > > > command into, say, /etc/local.d/raid.start? The machine doesn't boot > > > from /dev/md0. > > > For this, the kernel needs to be able to assemble the drives into the > raid at booting up time, and for that you need version 0.90 metadata. > (Or, at least, you did back in 2017.) >
Can't say I've tried it recently, but I'd be shocked if it changed much. The linux kernel guys generally consider this somewhat deprecated behavior, and prefer that users use an initramfs for this sort of thing. It is exactly the sort of problem an initramfs was created to fix. Honestly, I'd just bite the bullet and use dracut if you want your OS on RAID/etc. It is basically a one-liner at this point to install and a relatively small tweak to your GRUB config (automatic if using mkconfig). Dracut will respect your mdadm.conf, and just about all your other config info in /etc. The only gotcha is rebuilding your initramfs if it drastically changes (but, drastically changing your root filesystem is something that requires care anyway). But, if you're not using an initramfs you can get the kernel to handle this. Just don't be surprised when it changes your device name or whatever. -- Rich