I’m stuck on emergency mode and I don’t know what to do. The main issue is that it asks for root password (or control-D to continue) but no matter what I do it just won’t respond. No password incorrect or anything, I’m just stuck at the prompt as if the keyboard doesn’t even work. Yet I can use the keyboard on grub.
The problem seems to be related to mounted files. I have several hard drives on my computer and I remember having set up on some file so they auto mount during boot, and while I haven’t touched that config in well over a year, things were working fine until it suddenly stopped booting last week. No idea what happened.
I’d look into the mounting, but I just can’t get past that emergency mode prompt. I can’t run any commands or do anything at all, really.
Any idea what I could try? Maybe some way to run commands pre emergency mode, maybe from grub or something?
I did try different ones from the grub menu, yes. Not all of them, but several, including first and last.
As for the messages, saving potential speeling mistakes as I’m retyping by hand:
[FAILED] failed to start Load AppArmor profiles
[FAILED] failed to start Load Kernel Modules
[FAILED] failed to mount Mount unit for core, revision 13250.
[FAILED] failed to mount Mount unit for git-cola, revision 136.
[FAILED] failed to mount /home/pina/windows.
[DEPEND] Dependency failed for Local File Systems.
You are in emergency mode. After logging in, type “journalclt -xb” to view system logs, “systemctl reboot” to reboot, “systemctl default” or “exit” to boot into default mode.
Give root password for maintenance
(or press Control-D to continue):
[manjaro@manjaro ~]$ sudo manjaro-chroot -a
grub-probe: error: cannot find a GRUB drive for /dev/sdc1. Check your device.map.
grub-probe: error: cannot find a GRUB drive for /dev/sdc1. Check your device.map.
==> Mounting (ManjaroLinux) [/dev/sdb1]
→ mount: [/mnt]
→ mount: [/mnt/home/pina/windows]
The disk contains an unclean file system (0, 0).
Metadata kept in Windows cache, refused to mount.
Falling back to read-only mount because the NTFS partition is in an
unsafe state. Please resume and shutdown Windows fully (no hibernation
or fast restarting.)
Could not mount read-write, trying read-only
[manjaro /]#
After the downloads, I got this. Does not look great
( 1/418) upgrading alsa-card-profiles [####################################################################] 100%
( 2/418) upgrading iana-etc [####################################################################] 100%
warning: /etc/locale.conf saved as /etc/locale.conf.pacsave
( 3/418) upgrading filesystem [####################################################################] 100%
error: extract: not overwriting dir with file /lib
error: problem occurred while upgrading filesystem
Note: locale.conf is not longer tracked by
package management. Restoring /etc/locale.conf …
error: could not commit transaction
error: failed to commit transaction (transaction aborted)
Errors occurred, no packages were upgraded.
Afterwards, when I tried rebooting manjaro, I now get:
error: file ‘/boot/vmlinu-5.10-x86_64’ not found.
error: you need to load the kernel first.
Press any key to continue…
Yeah, noticed that, although I thought that was Windows not closing after being told to close. IIRC, that’s what it keeps doing every time and wasn’t expecting to be directly related.
That said, when I execute it now (after brahma’s command), it no longer gives that message. I now get
[manjaro@manjaro ~]$ sudo manjaro-chroot -a
grub-probe: error: cannot find a GRUB drive for /dev/sdc1. Check your device.map.
grub-probe: error: cannot find a GRUB drive for /dev/sdc1. Check your device.map.
==> Mounting (ManjaroLinux) [/dev/sdb1]
→ mount: [/mnt]
→ mount: [/mnt/home/pina/windows]
[manjaro /]#
I probably should have stayed put, but I was searching for solution for the new error message and got me here, based on which I executed “pacman-mirrors -f 5 && pacman -Syyu” followed by update-grub. Now trying to launch manjaro gives me a black screen with nothing shown and windows is no longer showing as an option in Grub. So yay.
Anyway, as for your the command. Output is
[manjaro /]# mhwd-kernel -li
Currently running: 5.15.48-1-MANJARO (linux515)
The following kernels are installed in your system:
so first uninstall the 59 kernel: mhwd-kernel -r linux59
reinstall the 5.10 kernel: pacman -S linux510
then run these: update-grub mkinitcpio -P exit systemctl reboot
and see if it worked
I am assuming this will be a problem, copying it here before I reboot. The other commands seem to have worked.
[manjaro /]# mkinitcpio -P
==> Building image from preset: /etc/mkinitcpio.d/linux510.preset: 'default'
-> -k /boot/vmlinuz-5.10-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-5.10-x86_64.img
==> ERROR: '/lib/modules/5.10.124-1-MANJARO' is not a valid kernel module directory
==> Building image from preset: /etc/mkinitcpio.d/linux510.preset: 'fallback'
-> -k /boot/vmlinuz-5.10-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-5.10-x86_64-fallback.img -S autodetect
==> ERROR: '/lib/modules/5.10.124-1-MANJARO' is not a valid kernel module directory
==> Building image from preset: /etc/mkinitcpio.d/linux54.preset: 'default'
-> -k /boot/vmlinuz-5.4-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-5.4-x86_64.img
==> ERROR: '/lib/modules/5.4.200-1-MANJARO' is not a valid kernel module directory
==> Building image from preset: /etc/mkinitcpio.d/linux54.preset: 'fallback'
-> -k /boot/vmlinuz-5.4-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-5.4-x86_64-fallback.img -S autodetect
==> ERROR: '/lib/modules/5.4.200-1-MANJARO' is not a valid kernel module directory
==> Building image from preset: /etc/mkinitcpio.d/linux57.preset: 'default'
-> -k /boot/vmlinuz-5.7-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-5.7-x86_64.img
==> ERROR: '/lib/modules/5.7.19-2-MANJARO' is not a valid kernel module directory
==> Building image from preset: /etc/mkinitcpio.d/linux57.preset: 'fallback'
-> -k /boot/vmlinuz-5.7-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-5.7-x86_64-fallback.img -S autodetect
==> ERROR: '/lib/modules/5.7.19-2-MANJARO' is not a valid kernel module directory
Upon reboot, when I choose to boot manjaro, I just get an empty black screen without any messages at all. I’m letting it run to see if it just needs a while to get things in order internally
The uninstall and the kernel reinstall seemed to work, at least. mkinitcpio -P gave a lot of errors, as pasted above. And after reboot the screen is still black, so something did go wrong.
so again chroot, reinstalling your video drivers may help…
post output from: mhwd -l && mhwd -li ls /etc/mkinitcpio.d/*.preset sudo ls /boot/initramfs-* sudo ls /boot/vmlinuz-* sudo ls /usr/lib/modules/*