I am on BTRFS, systemd-boot.
My system was working fine for long time. But as I was playing with python for a few days, I found Calibre unable to convert PDF files to AZW.
So I thought I restore to a previous snapshot 18 March (used BTRFS Assistant), which I did and rebooted instantly.
Rebooting I get the black screen with a message saying Failed to mount EFI, and an option to either enter root password or CTL-D.
you need to chroot into your installation and fix it.
Looking at that:
it seems like you haven’t updated in a long time (arch-kernel is at 6.2.8 now) and somehow got a partial update situation, so maybe chrooting in and installing updates MIGHT already do the trick
Thanks @BS86
No, I am sure I am updated up to just a few minutes before having this issue.
It was strange for me that restoring the system to previous snapshot broke it as described.
So, what can I do? I will appreciate step by step instructions from that screen I mentioned. (sorry, I am not that techie!)
Thank you
Kernel is outside of your Btrfs system when using Systemd-boot, this is why simply restoring the snapshot does not help you and fixing is not enough. We warned you long ago.
You need to chroot to your system and mount /efi, then reinstall correct Kernel version that should match the snapshot.
Sure! Whatever happens to my system is my fault anyway. It is me who does it!
So, with systemd-boot I should forget about BTRFS Assistant and snapshotting the system as it it pointless?
I will appreciate simple step by step instructions to do it if possible.
well, 5.19.4 was the up-to-date kernel in August 2022 - so the snapshot you used must have been created several months ago or you did not update regularly. There were several breaking changes since then.
I am not used to btrfs, and using btrfs with systemd-boot is not recommended, so I can’t help with that.
I wonder if I am getting this correct. Can I reboot, then at the prompt I get I enter the root password then yay lts?
Or I do both?
Sorry if am not that techie. I never tried chroot before!
I do it from the already booted from USB or reboot and enter root password and do the commands?
Update:
Thanks a billion @Zesko for giving me step by step commands.
[liveuser@eos-2022.08.28 ~]$ sudo mount /dev/nvme0n1p2 /mnt
mount: /mnt: /dev/nvme0n1p2 already mounted on /run/media/liveuser/39326df8-bcf7-4bef-b8b7-23fa3e95f8ed.
dmesg(1) may have more information after failed mount system call.
[liveuser@eos-2022.08.28 ~]$
Is this OK? should I do the next command?
(I wonder why removed detailed commands!)
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@ /dev/nvme0n1p2 /mnt
mount: /mnt: /dev/nvme0n1p2 already mounted on /run/media/liveuser/39326df8-bcf7-4bef-b8b7-23fa3e95f8ed.
dmesg(1) may have more information after failed mount system call.
[liveuser@eos-2022.08.28 ~]$ sudo mount /dev/nvme0n1p1 /mnt/efi
mount: /mnt/efi: mount point does not exist.
dmesg(1) may have more information after failed mount system call.
[liveuser@eos-2022.08.28 ~]$
[liveuser@eos-2022.08.28 ~]$ sudo umount /run/media/liveuser/39326df8-bcf7-4bef-b8b7-23fa3e95f8ed
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@ /dev/nvme0n1p2 /mnt
mount: /mnt: /dev/nvme0n1p2 already mounted on /mnt.
dmesg(1) may have more information after failed mount system call.
[liveuser@eos-2022.08.28 ~]$ sudo mount /dev/nvme0n1p1 /mnt/efi
mount: /mnt/efi: mount point does not exist.
dmesg(1) may have more information after failed mount system call.
[liveuser@eos-2022.08.28 ~]$
[liveuser@eos-2022.08.28 ~]$ sudo umount /mnt
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@ /dev/nvme0n1p2 /mnt
[liveuser@eos-2022.08.28 ~]$ sudo mount /dev/nvme0n1p1 /mnt/efi
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@log /dev/nvme0n1p2 /mnt/var/log
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@cache /dev/nvme0n1p2 /mnt/var/cache
[liveuser@eos-2022.08.28 ~]$ sudo arch-chroot /mnt
[root@EndeavourOS /]# pacman -S linux-lts
error: failed to init transaction (unable to lock database)
error: could not lock database: File exists
if you're sure a package manager is not already
running, you can remove /var/lib/pacman/db.lck
[root@EndeavourOS /]# sudo pacman -S linux-lts
error: failed to init transaction (unable to lock database)
error: could not lock database: File exists
if you're sure a package manager is not already
running, you can remove /var/lib/pacman/db.lck
[root@EndeavourOS /]#
[liveuser@eos-2022.08.28 ~]$ rm /var/lib/pacman/db.lck
rm: cannot remove '/var/lib/pacman/db.lck': No such file or directory
[liveuser@eos-2022.08.28 ~]$ sudo umount /mnt
umount: /mnt: not mounted.
[liveuser@eos-2022.08.28 ~]$ rm /var/lib/pacman/db.lck
rm: cannot remove '/var/lib/pacman/db.lck': No such file or directory
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@ /dev/nvme0n1p2 /mnt
[liveuser@eos-2022.08.28 ~]$ sudo mount /dev/nvme0n1p1 /mnt/efi
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@log /dev/nvme0n1p2 /mnt/var/log
[liveuser@eos-2022.08.28 ~]$ sudo mount -o subvol=@cache /dev/nvme0n1p2 /mnt/var/cache
[liveuser@eos-2022.08.28 ~]$ sudo arch-chroot /mnt
[root@EndeavourOS /]# pacman -S linux-lts
warning: linux-lts-6.1.20-1 is up to date -- reinstalling
resolving dependencies...
looking for conflicting packages...
Package (1) Old Version New Version Net Change
core/linux-lts 6.1.20-1 6.1.20-1 0.00 MiB
Total Installed Size: 164.03 MiB
Net Upgrade Size: 0.00 MiB
:: Proceed with installation? [Y/n]
(1/1) checking keys in keyring [--------------------------------] 100%
(1/1) checking package integrity [--------------------------------] 100%
(1/1) loading package files [--------------------------------] 100%
(1/1) checking for file conflicts [--------------------------------] 100%
:: Running pre-transaction hooks...
(1/1) Performing snapper pre snapshots for the following configurations...
==> root: 5530
:: Processing package changes...
(1/1) reinstalling linux-lts [--------------------------------] 100%
:: Running post-transaction hooks...
(1/6) Arming ConditionNeedsUpdate...
(2/6) Updating module dependencies...
(3/6) Running kernel-install...
:: Running kernel-install for kernel 6.1.20-1-lts
dracut: Executing: /usr/bin/dracut --hostonly --no-hostonly-cmdline -f /efi/a9d690a5d1c144ee81cbb0b9de665c13/6.1.20-1-lts/initrd 6.1.20-1-lts
dracut: dracut module 'dash' will not be installed, because command 'dash' could not be found!
dracut: dracut module 'mksh' will not be installed, because command 'mksh' could not be found!
dracut: dracut module 'busybox' will not be installed, because command 'busybox' could not be found!
dracut: dracut module 'dbus-broker' will not be installed, because command 'dbus-broker' could not be found!
dracut: dracut module 'rngd' will not be installed, because command 'rngd' could not be found!
dracut: dracut module 'network-wicked' will not be installed, because command 'wicked' could not be found!
dracut: dracut module 'dmraid' will not be installed, because command 'kpartx' could not be found!
dracut: dracut module 'tpm2-tss' will not be installed, because command 'tpm2' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsi-iname' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsiadm' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsid' could not be found!
dracut: dracut module 'nvmf' will not be installed, because command 'nvme' could not be found!
dracut: dracut module 'biosdevname' will not be installed, because command 'biosdevname' could not be found!
dracut: dracut module 'memstrack' will not be installed, because command 'memstrack' could not be found!
dracut: memstrack is not available
dracut: If you need to use rd.memdebug>=4, please install memstrack and procps-ng
dracut: dracut module 'squash' will not be installed, because command 'mksquashfs' could not be found!
dracut: dracut module 'squash' will not be installed, because command 'unsquashfs' could not be found!
dracut: dracut module 'dash' will not be installed, because command 'dash' could not be found!
dracut: dracut module 'mksh' will not be installed, because command 'mksh' could not be found!
dracut: dracut module 'busybox' will not be installed, because command 'busybox' could not be found!
dracut: dracut module 'dbus-broker' will not be installed, because command 'dbus-broker' could not be found!
dracut: dracut module 'rngd' will not be installed, because command 'rngd' could not be found!
dracut: dracut module 'network-wicked' will not be installed, because command 'wicked' could not be found!
dracut: dracut module 'dmraid' will not be installed, because command 'kpartx' could not be found!
dracut: dracut module 'tpm2-tss' will not be installed, because command 'tpm2' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsi-iname' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsiadm' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsid' could not be found!
dracut: dracut module 'nvmf' will not be installed, because command 'nvme' could not be found!
dracut: dracut module 'memstrack' will not be installed, because command 'memstrack' could not be found!
dracut: memstrack is not available
dracut: If you need to use rd.memdebug>=4, please install memstrack and procps-ng
dracut: dracut module 'squash' will not be installed, because command 'mksquashfs' could not be found!
dracut: dracut module 'squash' will not be installed, because command 'unsquashfs' could not be found!
dracut: *** Including module: systemd ***
dracut: *** Including module: systemd-initrd ***
dracut: *** Including module: i18n ***
dracut: *** Including module: btrfs ***
dracut: *** Including module: kernel-modules ***
dracut: *** Including module: kernel-modules-extra ***
dracut: *** Including module: rootfs-block ***
dracut: *** Including module: terminfo ***
dracut: *** Including module: udev-rules ***
dracut: Skipping udev rule: 40-redhat.rules
dracut: Skipping udev rule: 50-firmware.rules
dracut: Skipping udev rule: 50-udev.rules
dracut: Skipping udev rule: 91-permissions.rules
dracut: Skipping udev rule: 80-drivers-modprobe.rules
dracut: Skipping udev rule: 70-persistent-net.rules
dracut: *** Including module: dracut-systemd ***
dracut: *** Including module: usrmount ***
dracut: *** Including module: base ***
dracut: *** Including module: fs-lib ***
dracut: *** Including module: shutdown ***
dracut: *** Including modules done ***
dracut: *** Installing kernel module dependencies ***
dracut: *** Installing kernel module dependencies done ***
dracut: *** Resolving executable dependencies ***
dracut: *** Resolving executable dependencies done ***
dracut: *** Hardlinking files ***
dracut: Mode: real
dracut: Method: sha256
dracut: Files: 766
dracut: Linked: 1 files
dracut: Compared: 0 xattrs
dracut: Compared: 45 files
dracut: Saved: 692 B
dracut: Duration: 0.003229 seconds
dracut: *** Hardlinking files done ***
dracut: *** Generating early-microcode cpio image ***
dracut: *** Using microcode found in '/boot/intel-ucode.img' ***
dracut: *** Store current command line parameters ***
dracut: *** Stripping files ***
dracut: *** Stripping files done ***
dracut: *** Creating image file '/efi/a9d690a5d1c144ee81cbb0b9de665c13/6.1.20-1-lts/initrd' ***
dracut: dracut: using auto-determined compression method 'gzip'
dracut: *** Creating initramfs image file '/efi/a9d690a5d1c144ee81cbb0b9de665c13/6.1.20-1-lts/initrd' done ***
dracut: Executing: /usr/bin/dracut --no-hostonly --force /efi/a9d690a5d1c144ee81cbb0b9de665c13/6.1.20-1-lts/initrd-fallback 6.1.20-1-lts
dracut: dracut module 'dash' will not be installed, because command 'dash' could not be found!
dracut: dracut module 'mksh' will not be installed, because command 'mksh' could not be found!
dracut: dracut module 'busybox' will not be installed, because command 'busybox' could not be found!
dracut: dracut module 'dbus-broker' will not be installed, because command 'dbus-broker' could not be found!
dracut: dracut module 'rngd' will not be installed, because command 'rngd' could not be found!
dracut: dracut module 'network-wicked' will not be installed, because command 'wicked' could not be found!
dracut: dracut module 'dmraid' will not be installed, because command 'kpartx' could not be found!
dracut: dracut module 'multipath' will not be installed, because command 'multipath' could not be found!
dracut: dracut module 'tpm2-tss' will not be installed, because command 'tpm2' could not be found!
dracut: dracut module 'fcoe' will not be installed, because command 'dcbtool' could not be found!
dracut: dracut module 'fcoe' will not be installed, because command 'fipvlan' could not be found!
dracut: dracut module 'fcoe' will not be installed, because command 'lldpad' could not be found!
dracut: dracut module 'fcoe' will not be installed, because command 'fcoemon' could not be found!
dracut: dracut module 'fcoe' will not be installed, because command 'fcoeadm' could not be found!
dracut: dracut module 'fcoe-uefi' will not be installed, because command 'dcbtool' could not be found!
dracut: dracut module 'fcoe-uefi' will not be installed, because command 'fipvlan' could not be found!
dracut: dracut module 'fcoe-uefi' will not be installed, because command 'lldpad' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsi-iname' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsiadm' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsid' could not be found!
dracut: dracut module 'nvmf' will not be installed, because command 'nvme' could not be found!
dracut: dracut module 'biosdevname' will not be installed, because command 'biosdevname' could not be found!
dracut: dracut module 'memstrack' will not be installed, because command 'memstrack' could not be found!
dracut: memstrack is not available
dracut: If you need to use rd.memdebug>=4, please install memstrack and procps-ng
dracut: dracut module 'squash' will not be installed, because command 'mksquashfs' could not be found!
dracut: dracut module 'squash' will not be installed, because command 'unsquashfs' could not be found!
dracut: *** Including module: bash ***
dracut: *** Including module: systemd ***
dracut: *** Including module: systemd-initrd ***
dracut: *** Including module: modsign ***
dracut: *** Including module: dbus-daemon ***
dracut: *** Including module: dbus ***
dracut: *** Including module: i18n ***
dracut: *** Including module: network-manager ***
dracut: *** Including module: network ***
dracut: *** Including module: btrfs ***
dracut: *** Including module: crypt ***
dracut: *** Including module: dm ***
dracut: Skipping udev rule: 64-device-mapper.rules
dracut: Skipping udev rule: 60-persistent-storage-dm.rules
dracut: Skipping udev rule: 55-dm.rules
dracut: *** Including module: kernel-modules ***
dracut: *** Including module: kernel-modules-extra ***
dracut: *** Including module: kernel-network-modules ***
dracut: *** Including module: lvm ***
dracut: Skipping udev rule: 64-device-mapper.rules
dracut: Skipping udev rule: 56-lvm.rules
dracut: Skipping udev rule: 60-persistent-storage-lvm.rules
dracut: *** Including module: mdraid ***
dracut: Skipping udev rule: 64-md-raid.rules
dracut: *** Including module: nvdimm ***
dracut: *** Including module: qemu ***
dracut: *** Including module: qemu-net ***
dracut: *** Including module: cifs ***
dracut: *** Including module: lunmask ***
dracut: *** Including module: nbd ***
dracut: *** Including module: nfs ***
dracut: *** Including module: resume ***
dracut: *** Including module: rootfs-block ***
dracut: *** Including module: terminfo ***
dracut: *** Including module: udev-rules ***
dracut: Skipping udev rule: 40-redhat.rules
dracut: Skipping udev rule: 50-firmware.rules
dracut: Skipping udev rule: 50-udev.rules
dracut: Skipping udev rule: 91-permissions.rules
dracut: Skipping udev rule: 80-drivers-modprobe.rules
dracut: *** Including module: dracut-systemd ***
dracut: *** Including module: usrmount ***
dracut: *** Including module: base ***
dracut: *** Including module: fs-lib ***
dracut: *** Including module: shutdown ***
dracut: *** Including modules done ***
dracut: *** Installing kernel module dependencies ***
dracut: *** Installing kernel module dependencies done ***
dracut: *** Resolving executable dependencies ***
dracut: *** Resolving executable dependencies done ***
dracut: *** Hardlinking files ***
dracut: Mode: real
dracut: Method: sha256
dracut: Files: 2476
dracut: Linked: 9 files
dracut: Compared: 0 xattrs
dracut: Compared: 464 files
dracut: Saved: 1.42 MiB
dracut: Duration: 0.022233 seconds
dracut: *** Hardlinking files done ***
dracut: *** Generating early-microcode cpio image ***
dracut: *** Constructing AuthenticAMD.bin ***
dracut: *** Using microcode found in '/boot/intel-ucode.img' ***
dracut: *** Store current command line parameters ***
dracut: *** Stripping files ***
dracut: *** Stripping files done ***
dracut: *** Creating image file '/efi/a9d690a5d1c144ee81cbb0b9de665c13/6.1.20-1-lts/initrd-fallback' ***
dracut: dracut: using auto-determined compression method 'gzip'
cp: error writing '/efi/a9d690a5d1c144ee81cbb0b9de665c13/6.1.20-1-lts/initrd-fallback': No space left on device
dracut: dracut: creation of /efi/a9d690a5d1c144ee81cbb0b9de665c13/6.1.20-1-lts/initrd-fallback failed
Running in a chroot, skipping cmdline generation
(4/6) Check if user should be informed about rebooting after certain system package upgrades.
(5/6) Checking which packages need to be rebuilt
(6/6) Performing snapper post snapshots for the following configurations...
==> root: 5531
[root@EndeavourOS /]# exit
exit
[liveuser@eos-2022.08.28 ~]$