You are not logged in.

#1 2022-05-25 14:03:48

Rurisk
Member
Registered: 2018-02-18
Posts: 3

[Solved] System fails to boot after upgrade

I'm really not sure how this problem occurred, but I went back through my FSTab from scratch and reinstalled Grub again and my desktop, 24 hours later (!) is back fully functional.


Some time ago I did a system upgrade, and after a shutdown and restart I had the following error:

Starting Version 251-1-arch
Scanning for Btrfs filesystems
ERROR: device '/dev/mapper/luksRoot' does not exist
dmesg(1) may have more information after failed mount system calls
you are now being dropped to the emergency shell

I've tried downgrading the system to regain access which worked at first but now since returning from work and attempting to upgrade/fix I get the same issue, and downgrading isn't helping. Unfortunately, I work away a lot, and as a result, I have struggled to be able to look into the problem properly for some time.

I'm at a loss now, after hours of digging. I don't know what could have caused this issue.

I have tried triple-checking the FSTAB but I cannot see what could be wrong with it. I have been back through the GRUB installation about 20 times, trying advice from the wiki multiple times on the off chance but no luck. I tweaked mkinitcpio but again, took me nowhere. Any advice or pointers at all will be really appreciated.

This is the output of my /etc/fstab:

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/         	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=256,subvol=/@	0 0

# /dev/nvme0n1p1 LABEL=EFI
UUID=3507-603E      	/efi      	vfat      	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro	0 2

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/usr      	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=260,subvol=/@usr	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/usr/local	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=261,subvol=/@usr/local	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/.snapshots	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=258,subvol=/@snapshots	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/var      	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=263,subvol=/@var	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/var/log  	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=264,subvol=/@var/log	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/var/lib  	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=265,subvol=/@var/lib	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/var/abs  	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=267,subvol=/@var/abs	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/var/tmp  	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=268,subvol=/@var/tmp	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/var/srv  	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=269,subvol=/@var/srv	0 0

# /dev/mapper/luksRoot LABEL=root
UUID=5e8ca029-1c33-44ae-be17-268838dfbb25	/var/cache/pacman/pkg	btrfs     	rw,noatime,nodiratime,compress=zstd:3,ssd,discard=async,space_cache,subvolid=271,subvol=/@pkg	0 0

My /etc/mkinicpio.conf:

# vim:set ft=sh
# MODULES
# The following modules are loaded before any boot hooks are
# run.  Advanced users may wish to specify all system modules
# in this array.  For instance:
#     MODULES=(piix ide_disk reiserfs)
MODULES=()

# BINARIES
# This setting includes any additional binaries a given user may
# wish into the CPIO image.  This is run last, so it may be used to
# override the actual binaries included by a given hook
# BINARIES are dependency parsed, so you may safely ignore libraries
BINARIES=(/usr/bin/btrfs)

# FILES
# This setting is similar to BINARIES above, however, files are added
# as-is and are not parsed in any way.  This is useful for config files.
FILES=(/etc/keyfiles/luksRoot.bin)

# HOOKS
# This is the most important setting in this file.  The HOOKS control the
# modules and scripts added to the image, and what happens at boot time.
# Order is important, and it is recommended that you do not change the
# order in which HOOKS are added.  Run 'mkinitcpio -H <hook name>' for
# help on a given hook.
# 'base' is _required_ unless you know precisely what you are doing.
# 'udev' is _required_ in order to automatically load modules
# 'filesystems' is _required_ unless you specify your fs modules in MODULES
# Examples:
##   This setup specifies all modules in the MODULES setting above.
##   No raid, lvm2, or encrypted root is needed.
#    HOOKS=(base)
#
##   This setup will autodetect all modules for your system and should
##   work as a sane default
#    HOOKS=(base udev autodetect block filesystems)
#
##   This setup will generate a 'full' image which supports most systems.
##   No autodetection is done.
#    HOOKS=(base udev block filesystems)
#
##   This setup assembles a pata mdadm array with an encrypted root FS.
##   Note: See 'mkinitcpio -H mdadm' for more information on raid devices.
#    HOOKS=(base udev block mdadm encrypt filesystems)
#
##   This setup loads an lvm2 volume group on a usb device.
#    HOOKS=(base udev block lvm2 filesystems)
#
##   NOTE: If you have /usr on a separate partition, you MUST include the
#    usr, fsck and shutdown hooks.
HOOKS=(base usr encrypt2 encrypt shutdown keyboard udev autodetect modconf block keymap btrfs filesystems fsck grub-btrfs-overlayfs)

# COMPRESSION
# Use this to compress the initramfs image. By default, zstd compression
# is used. Use 'cat' to create an uncompressed image.
#COMPRESSION="zstd"
#COMPRESSION="gzip"
#COMPRESSION="bzip2"
#COMPRESSION="lzma"
#COMPRESSION="xz"
#COMPRESSION="lzop"
#COMPRESSION="lz4"

# COMPRESSION_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=()

and my /etc/default/grub:

# GRUB boot loader configuration

GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="Arch"
GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet cryptdevice=UUID=ef36e2a0-6103-4e32-800b-2a28c256ddf3:luksRoot root=/dev/mapper/luksRoot amdgpu.ppfeaturemask=0xffffffff"
#GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet cryptdevice=UUID=5e8ca029-1c33-44ae-be17-268838dfbb25:luksRoot root=/dev/mapper/luksRoot amdgpu.ppfeaturemask=0xffffffff"
GRUB_CMDLINE_LINUX="cryptkey=rootfs:/etc/keyfiles/luksRoot.bin"

# Preload both GPT and MBR modules so that they are not missed
GRUB_PRELOAD_MODULES="part_gpt part_msdos"

# Uncomment to enable booting from LUKS encrypted devices
GRUB_ENABLE_CRYPTODISK=y

# Set to 'countdown' or 'hidden' to change timeout behavior,
# press ESC key to display menu.
GRUB_TIMEOUT_STYLE=menu

# Uncomment to use basic console
GRUB_TERMINAL_INPUT=console

# Uncomment to disable graphical terminal
#GRUB_TERMINAL_OUTPUT=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
GRUB_GFXMODE=auto

# Uncomment to allow the kernel use the same resolution used by grub
GRUB_GFXPAYLOAD_LINUX=keep

# Uncomment if you want GRUB to pass to the Linux kernel the old parameter
# format "root=/dev/xxx" instead of "root=/dev/disk/by-uuid/xxx"
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
GRUB_DISABLE_RECOVERY=true

# Uncomment and set to the desired menu colors.  Used by normal and wallpaper
# modes only.  Entries specified as foreground/background.
#GRUB_COLOR_NORMAL="light-blue/black"
#GRUB_COLOR_HIGHLIGHT="light-cyan/blue"

# Uncomment one of them for the gfx desired, a image background or a gfxtheme
#GRUB_BACKGROUND="/path/to/wallpaper"
#GRUB_THEME="/path/to/gfxtheme"

# Uncomment to get a beep at GRUB start
#GRUB_INIT_TUNE="480 440 1"

# Uncomment to make GRUB remember the last selection. This requires
# setting 'GRUB_DEFAULT=saved' above.
#GRUB_SAVEDEFAULT=true

# Uncomment to disable submenus in boot menu
#GRUB_DISABLE_SUBMENU=y

Last edited by Rurisk (2022-05-25 19:21:29)

Offline

Board footer

Powered by FluxBB