Saturday, May 4, 2024
 Popular · Latest · Hot · Upcoming
1
rated 0 times [  1] [ 0]  / answers: 1 / hits: 8320  / 3 Years ago, mon, november 1, 2021, 2:47:59

After running apt-get upgrade yesterday and shutting down, I'm no longer able to boot Ubuntu 15.



The last several lines I see during boot are:



Begin: Running /scripts/init-premount ... done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.


My hard disk is encrypted, so normally I would get a Passphrase prompt here. However, after a little while, I just get:



mdadm: CREATE group disk not found


This message repeats ad infinitum and I'm not able to boot. Same with recovery mode.



I found a few threads about this error, but no solution yet. What can I do to diagnose and fix this problem?



Thank you!


More From » boot

 Answers
1

This error is generated by the initramfs script that finds and mounts the root fs.



I've experienced this message before and it turned out to be caused by updating the initramfs from a live cd.



The thing was that I had an encrypted root, and when opening the luks volume from the live cd I didn't use the same name that was in my crypttab.



So, I booted the live cd and did:



cryptsetup luksOpen /dev/md1 md1
vgchange -ay
mount /dev/vgmain/lvroot /mnt/custom
<... mount dev et. al ...>
chroot /mnt/custom
<... fix something ...>
update-initramfs -u
exit
umount /mnt/custom && vgchange -an && cryptsetup luksClose md1


The update-initramfs -u did warn about cryptsetup: WARNING: invalid line in /etc/crypttab - but at first I didn't deem it important.



After some failed attempts to boot it hit me: my crypttab had md1_crypt for the luks volume, but when I updated the initramfs it saw md1 so it went with that. From within the boot scripts md1 was not available as a luks volume.



So I booted my livecd again and corrected it:



cryptsetup luksOpen /dev/md1 md1_crypt
vgchange -ay
mount /dev/vgmain/lvroot /mnt/custom
<... mount dev et. al ...>
chroot /mnt/custom
update-initramfs -u
exit
umount /mnt/custom
vgchange -an
cryptsetup luksClose md1_crypt


I've looked through the initramfs-tools scripts, but I couldn't find the exact spot where this went wrong, so I assume it was just some weird interaction between cryptsetup, mdadm and lvm.



On another debian host I had a similar issue*, except this time without crypttools or lvm involved, and I was able to work around it by changing my mdadm.conf from /dev/md/n device paths to /dev/mdn. On this ocassion, the issue only presented itself while the array was rebuilding and not when everything was normal.



Perhaps someone more familiar with the inner workings of initramfs-tools can figure this out.



* the debian host also showed a message like incrementally starting raid arrays after a few CREATE group disk not found.


[#18169] Monday, November 1, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
calcur

Total Points: 189
Total Questions: 80
Total Answers: 95

Location: Burkina Faso
Member since Thu, Dec 15, 2022
1 Year ago
;