ERROR: device not found, drops to emergency shell

I dual boot EndeavorOS and Windows10, after an update and a restart I get this error when trying to boot the main entry of my grub menu


I can’t type in this emergency shell and I’m not sure how to proceed with recovery.
I’ve included my fstab and grub config below which I can access by booting the ‘fallback initramfs’ option.

my main questions are,

  1. how do I allow myself to type in the emergency shell?
  2. how do I fix my main boot option, which I assume is the one I should be using.

fstab

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a device; this may
# be used with UUID= as a more robust way to name devices that works even if
# disks are added and removed. See fstab(5).
#
# <file system>             <mount point>  <type>  <options>  <dump>  <pass>
UUID=8813-2A6B                            /boot/efi      vfat    defaults,noatime 0 2
UUID=859cc0a9-bb8c-435f-a0a6-41312b22f388 /              ext4    defaults,noatime 0 1
/dev/sda1  /mnt/data     ext4    defaults 0 0

GRUB Config

#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
  load_env
fi
if [ "${next_entry}" ] ; then
   set default="${next_entry}"
   set next_entry=
   save_env next_entry
   set boot_once=true
else
   set default="0"
fi

if [ x"${feature_menuentry_id}" = xy ]; then
  menuentry_id_option="--id"
else
  menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z "${boot_once}" ]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}

function load_video {
  if [ x$feature_all_video_module = xy ]; then
    insmod all_video
  else
    insmod efi_gop
    insmod efi_uga
    insmod ieee1275_fb
    insmod vbe
    insmod vga
    insmod video_bochs
    insmod video_cirrus
  fi
}

if [ x$feature_default_font_path = xy ] ; then
   font=unicode
else
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root 859cc0a9-bb8c-435f-a0a6-41312b22f388
    font="/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
  set gfxmode=auto
  load_video
  insmod gfxterm
  set locale_dir=$prefix/locale
  set lang=en_AU
  insmod gettext
fi
terminal_input console
terminal_output gfxterm
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root 859cc0a9-bb8c-435f-a0a6-41312b22f388
insmod png
background_image -m stretch /usr/share/endeavouros/splash.png
if [ x$feature_timeout_style = xy ] ; then
  set timeout_style=menu
  set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
  set timeout=5
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'EndeavourOS Linux, with Linux linux' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-advanced-859cc0a9-bb8c-435f-a0a6-41312b22f388' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_gpt
        insmod ext2
        search --no-floppy --fs-uuid --set=root 859cc0a9-bb8c-435f-a0a6-41312b22f388
        echo    'Loading Linux linux ...'
        linux   /boot/vmlinuz-linux root=UUID=859cc0a9-bb8c-435f-a0a6-41312b22f388 rw  amdgpu.ppfeaturemask=0xffffffff loglevel=3 nowatchdog nvme_load=YES
        echo    'Loading initial ramdisk ...'
        initrd  /boot/amd-ucode.img /boot/initramfs-linux.img
}
menuentry 'EndeavourOS Linux, with Linux linux (fallback initramfs)' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-fallback-859cc0a9-bb8c-435f-a0a6-41312b22f388' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_gpt
        insmod ext2
        search --no-floppy --fs-uuid --set=root 859cc0a9-bb8c-435f-a0a6-41312b22f388
        echo    'Loading Linux linux ...'
        linux   /boot/vmlinuz-linux root=UUID=859cc0a9-bb8c-435f-a0a6-41312b22f388 rw  amdgpu.ppfeaturemask=0xffffffff loglevel=3 nowatchdog nvme_load=YES
        echo    'Loading initial ramdisk ...'
        initrd  /boot/amd-ucode.img /boot/initramfs-linux-fallback.img
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Windows Boot Manager (on /dev/sdb2)' --class windows --class os $menuentry_id_option 'osprober-efi-CE27-F8DF' {
        insmod part_gpt
        insmod fat
        set root='hd1,gpt2'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd1,gpt2 --hint-efi=hd1,gpt2 --hint-baremetal=ahci1,gpt2  CE27-F8DF
        else
          search --no-floppy --fs-uuid --set=root CE27-F8DF
        fi
        chainloader /efi/Microsoft/Boot/bootmgfw.efi
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
if [ "$grub_platform" = "efi" ]; then
        fwsetup --is-supported
        if [ "$?" = 0 ]; then
                menuentry 'UEFI Firmware Settings' $menuentry_id_option 'uefi-firmware' {
                        fwsetup
                }
        fi
fi
### END /etc/grub.d/30_uefi-firmware ###

### BEGIN /etc/grub.d/35_fwupd ###
### END /etc/grub.d/35_fwupd ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f  ${config_directory}/custom.cfg ]; then
  source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f  $prefix/custom.cfg ]; then
  source $prefix/custom.cfg
fi
### END /etc/grub.d/41_custom ###

Can you run blkid so we can see what your UUIDs are?

2 Likes

Here you go!
doesn’t look like the uuid of my NVME boot drive (nvme0n1p2) has changed

/dev/nvme0n1p1: UUID="8813-2A6B" BLOCK_SIZE="512" TYPE="vfat" PARTUUID="e29059b0-1e87-254c-9361-806425678f7f"
/dev/nvme0n1p2: UUID="859cc0a9-bb8c-435f-a0a6-41312b22f388" BLOCK_SIZE="4096" TYPE="ext4" PARTLABEL="root" PARTUUID="5ace0023-6394-3c4f-88d4-aa93d32815c7"
/dev/sdb4: BLOCK_SIZE="512" UUID="068428BD8428B0DB" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="fa10cc02-fff7-45af-b386-63a72b9e251e"
/dev/sdb2: UUID="CE27-F8DF" BLOCK_SIZE="512" TYPE="vfat" PARTLABEL="EFI system partition" PARTUUID="32ba2bac-92a8-4ea2-af39-0e82aa9cb8f5"
/dev/sdb3: PARTLABEL="Microsoft reserved partition" PARTUUID="482ba762-ae24-4db7-b7e6-821b1fe17397"
/dev/sdb1: BLOCK_SIZE="512" UUID="20601D51601D2F52" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="73184f2e-1f35-4775-879b-d228428a26b8"
/dev/sda1: UUID="8fdacfea-4528-4c90-92df-4970ccb251e0" BLOCK_SIZE="4096" TYPE="ext4" PARTLABEL="data" PARTUUID="2e8ec906-ce49-4c33-91bd-236f5dc5741c"

If your fallback entry is successful, it means the problem is the difference between normal and fallback entries, which is the modules that are included in the kernel images.

I would start from what system changes have been done before this happens, and look into /etc/mkinitcpio.conf (MODULES, or more keys).

I would try rebuilding your boot images.

If you are using mkinitcpio, run sudo mkinitcpio -P, if you are running dracut, run sudo dracut-rebuild

1 Like

This has fixed my problem thank you so much! is there anything I should do afterwards on the new image to make sure its stable or help prevent this kind of thing in future?

It is used to boot the system so if your system is booting properly and working it should be fine.

Without knowing what happened, it is somewhat hard to identify how to prevent it.

If it keeps happening, we can investigate it more, if not, I wouldn’t worry about it.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.