I was having trouble getting a new RAID array to assemble on startup, and before anyone responded to that post, I tried updating mdadm, but this ended up taking a very long time because of all the other dependencies. Somewhere in there it messed up something with my boot. I'm pretty sure grub was updated onto /dev/sda rather than the RAID array because I messed up (see below). But first, here is what is currently happening:
I have a RAID1 array,
/dev/md1, that is mounted at
/. I was able to boot until I ran the updates. Now when I boot I get
Gave up waiting for root device. Common problems: -Boot args (cat /proc/cmdline) #unchanged, I checked -Check rootdelay= (did the system wait long enough?) -Check root= (did the system wait for the right device?) #yes, correct UUID -Missing modules (cat /proc/modules; ls /dev) #think this is my error ALERT! /dev/disk/by-uui/1d3... does not exist. Dropping to a shell!
and then I am dropped into ash. blikd shows that all my HDDs are there, and registered as raid members, but there are no RAID arrays.
This is super easy to fix. I can run
mdadm --assemble --scan
which will create the RAID arrays, and cat
/proc/mdstat shows they are working fine. Then I merely give
exit, and it boots like a champ.
The trouble is I can't get it to do this automatically. It's not trying to assemble the arrays before looking for them.
What I THINK happened: As I was upgrading mdadm I was prompted to update grub, and it told me that I needed to select where to install it as the UUID had changed. I, being an idiot, looked at my fstab and misread a comment that said
#/ was on /dev/md1 during installation. I mistook this for
.../dev/sda1.... Like I said, idiot (I've barely slept tyring to sort all this stuff out). Anyways, this seemed to make sense to me, so I selected /dev/sda1 (or just sda, I forget) in the prompt and it went on its merry way. Then I rebooted and this happened.
So it appears that I mistakenly put grub on a different partition, and so it's tyring to boot from there rather than creating the RAID arrays and then boot from /dev/md1. There are a bunch of posts about this generic error, but none of them seem relevant to what I'm trying to do. Any ideas?