Permanent login incorrect

Hello everyone,

I’m experiencing an issue with my Asahi Fedora Remix KDE installation on a MacBook Pro M1 Pro (2021). After disabling the graphical target through systemd, I’ve been unable to log in. Every time I try to enter my login credentials in the (tty1), it keeps saying “login incorrect.” I’m 90% sure my login and password are correct.

Here’s what I’ve tried so far:

  1. Attempted to boot into single-user mode and recovery mode by setting bootargs in U-Boot:
    -setenv bootargs single
    -setenv bootargs graphical.target
    -setenv bootargs rescue
  2. None of these commands seemed to work. The system still boots into tty1, and I’m unable to make any progress.
  3. Root access is not an option for me as I can’t log in at all.

I’m new to Linux and don’t have much experience troubleshooting issues like this. Any guidance or suggestions would be greatly appreciated. How can I regain access to my system or at least troubleshoot the login issue?

Thank you in advance!

1 Like

You’re only 90% sure you are using the correct password, so lets remove that from the equation.

Log in to root on a TTY, reset the password for your main account with passwd mikhail where mikhail is your primary user.

Now try logging in with that userid and password.

Thank you for answer!

I’ve already tried accessing the root account, but I can’t log in as root either. It results in the same ‘login incorrect’ issue. Are there any alternative ways to reset the password or troubleshoot this without root access?

My mistake - I didn’t note that you’d already tried root acess.

Boot from a live image and chroot onto the problem filesystem and remove or change the password for your user.

The root account on Fedora is disabled by default, so you won’t be able to login into it. Also, on Asahi we use only u-boot to create the EFI environment for grub, so you can’t change the kernel cmdline from it, you need to do it from grub.

If you need to reset the password for your user, easiest is probably to enter the grub menu and edit the kernel cmdline to pass init=/bin/bash. Then boot the system and reset the password with something like:

# mount -o remount,rw /
# passwd username_to_reset
# touch /.autorelabel
# mount -o remount,ro /
# reboot

Replace username_to_reset with your actual username. This will, in order, make the filesystem writeable, reset the password, signal SELinux it will need to do a relabel on the next boot, remout read-only and reboot the system. The next boot will seems to hang for a few minutes while SELinux does its thing – leave it alone and it will eventually reboot by itself, and you should then be able to login with your new password.

1 Like

Thank you very much! I have a successfully enter into grub. However, there are some problems:
/sh: passwd: command not found

when I decided to look at what users are on the system
cat /etc/passwd I have return like
adm:x:… e.t.c,
but adm is not my login!

Thanks anyway

It’s possible that you don’t have your PATH set at that point. Try using /usr/bin/passwd instead. That will tell your shell just where to find the program.

This is the first thing I tried.
The problem is that there is no file passwd in the directory /etc/bin
Anyway, thanks for advice!

Try /usr/bin/passwd, not /etc/bin/passwd.

thanks for the help!
unfortunately the same mistake command not found

Try this:

which passwd

That will at least tell you where it is, assuming that it’s installed, and it certainly should be. Once you’ve found it, try this:

echo $PATH

to make sure it’s on your current path. If not, try running it with a fully qualified path to make sure your shell can find it.

SELinux seems to be the culprit here. I simply deleted my password via GRUB as described here: Permanent login incorrect - #5 by dcavalca

And then added autorelabel=1 into the GRUB menu entry, as described here:

The next thing was a terminal show, it took quite some time until all files got relabled. Now I can login again.