Hello everyone.
It seams that I really messed up somehow. Firstly, some context:
Today I turned on my PC and everything was fine, except that I couldn’t log in. Says “Failed to login”, and I’m 100% sure that caps lock was off, keyboard layout was right. Other tty showed “login incorrect”. So I started searching how to fix the problem online. In some topic I found that maybe a wrong version of some package making the problems, so I decided to chroot and run “pacman -Syu”. After reboot I ended up here:
You are in emergency mode. After logging in, type “journalctl -xb” to view system logs, “systemctl reboot” to reboot or"exit" to continue bootup.
Give root password for maintenance
(or press Control-D to continue):
I gave my password and system recognized it for the first(and last) time today. I typed “journalctl -xb” to see if there is anything useful for me. Then I typed “exit” to continue bootup and whole “You are in emergency mode…” appeared again with only difference that at this time when I try to enter my password it says “Login incorrect” - the same thing was when I tried to login in tty2 or tty3…
Pressing Ctrl+D doesn’t work - it just send me the same “You are in emergency mode…” message again. If I press it 5-6 times the message will stop appearing and everything will stuck on “Starting default.target” line.
Also, I just noticed what might cause emergency mode:
[FAILED] Failed to mount /efi.
See ‘systemctl status efi.mount’ for details.
[Depend] Dependency failed for Local File Systems.
I haven’t done anything special with the system in recent days and haven’t made any updates.
Please help
Did you try booting the fallback image from the boot menu? If that works, when you are in the system rebuild your initrds.
If not, maybe this helps. Chroot again and rebuild your initrds with the command dracut-rebuild if you are using dracut or mkinitcpio -P if you are using mkinitcpio.
Hello, thanks for response. Yes, I already tried booting the fallback and didn’t notice any changes.
And it fails to dracut-rebuild.
Couldn’t find EFI system partition. It is recommended to mount it to /boot or /efi.
Alternatively, use --esp-path= to specify path to mount point.
/usr/bin/dracut-rebuild: line 33: /dev/fd/63: No such file or directory
ugh, I guess it didn’t work.. while pacman -Syu dracut kernel-install-for-dracut:
:: Running post-transaction hooks…
(1/5) Reloading system manager configuration…
Skipped: Running in chroot.
(2/5) Restarting marked services…
Skipped: Running in chroot.
(3/5) Arming ConditionNeedsUpdate…
(4/5) Running kernel-install…
/usr/share/libalpm/scripts/kernel-install-hook: line 29: /dev/fd/63: No such file or directory
stat: cannot statx ‘/proc/1/root/.’: No such file or directory
Running in a chroot, skipping cmdline generation
(5/5) Checking which packages need to be rebuilt
join: /dev/fd/63: No such file or directory
comm: /dev/fd/62: No such file or directory
Error, do this: mount -t proc proc /proc
lscpu: failed to determine number of CPUs: /sys/devices/system/cpu/possible: No such file or directory
comm: /dev/fd/62: No such file or directory
tee: /tmp/tmp.y2UEQNM3z6/21374: No such file or directory
tee: /tmp/tmp.y2UEQNM3z6/25607: No such file or directory
comm: /dev/fd/62: No such file or directory
And when tried reinstall-kernels :
/usr/bin/reinstall-kernels: line 10: /dev/fd/63: No such file or directory
I fail to install LTS kernel. On several steps of install there is “No such file or directory” problems. For example:
stat: cannot statx ‘/proc/1/root/.’: No such file or directory
Running in a chroot, skipping cmdline generation
(4/5) Check if user should be informed about rebooting after certain system package upgrades.
stat: cannot statx ‘/proc/1/root/.’: No such file or directory
(5/5) Checking which packages need to be rebuilt
join: /dev/fd/63: No such file or directory
comm: /dev/fd/62: No such file or directory
Error, do this: mount -t proc proc /proc
lscpu: failed to determine number of CPUs: /sys/devices/system/cpu/possible: No such file or directory
tee: /tmp/tmp.nxqZR4J3Fp/10365: No such file or directory
comm: /dev/fd/62: No such file or directory
tee: /tmp/tmp.nxqZR4J3Fp/21626: No such file or directory
comm: /dev/fd/62: No such file or directory
Or when I do grub-mkconfig:
/usr/bin/grub-probe: error: cannot find a device for / (is /dev mounted?).
I really staring wonder how it came to this… I’m literally just updated the system through chroot…
Yes, sorry for the slow response. I just tried reinstall kernels in correct chroot and reboot to my system. It works! There is not a single problem left. Even the problem with login disappeared
Thanks for your guidance!