Gentoo + RAID + LVM + EVMS Boot or Mount Issues? Read this!
I put this here because I’ve been bitten by it several times now, and it sucks to have to figure it out each time, especially with that nagging niggle in the back of my head that I’ve done this before, just that the last time I rebooted the machine and had it was so long ago I can’t remember what the heck the fix was.
My fileserver has an odd RAID / LVM / EVMS setup where I have RAID, then LVM to define containers containing that RAID, then EVMS to contain those containers into a 700G filesystem called “storage” where “stuff” is kept. By default gentoo defines how the various disk management software starts up in /etc/conf.d/rc
RC_VOLUME_ORDER=”raid evms lvm dm”
I think that after the kernel has finished booting up the startup scripts will attempt to restart RAID on the system. Unfortunately, with the setup I have one of the disk management systems “grabs” one of the raid drives before RAID can be restarted and I end up with one disk giving “device or resource busy”. The RAID5 starts with a degraded volume and EVMS doesn’t start up right. Not fun.
The fix I found is simple. Change the setting to:
RC_VOLUME_ORDER=”evms lvm dm”
and the bootscripts will leave the already running RAID alone and just layer the LVM and EVMS volumes on top of it. Another solution I found was to just have “evms” in that line, but I discovered just now (rebooting again) that it appears to be the RAID that causes problems.
Needless it say it’s a big relief to know that my data is safe. I really have to find a better way to manage disks… laying volume management solutions on top of one another is not the way to do it. Unfortunately I don’t have the extra cash to lay out for 4 500G SATA disks in a RAID 1+0 (or 0+1?) array that would allow a disk to fail and still let me get to things.
You got that Alan? Now remember this next time your computer goes down. Of course it’s also the webserver holding this page which you won’t be able to …. uhmm… oh well, I’ve written about it now I can’t forget it!