Can't login as user or root after upgrade
I just upgraded my system and pacman finished without problems. Everything worked fine, but once I got up to get a cup of tea, my screensaver locked the screen, and since then I can't login anymore.
It just says "Incorrect login" for every user I tried. I checked the keyboard layout, made sure that I didn't missspelled anything etc. I tried loggin in locally through gdm, from a real tty, per ssh, all with the same effect.
I even bootet the installer, decrypted my hdd and arch-chroot'ed into my system to reset the password for my user and for root, but still get the same error.
Do you guys have any ideas how I can further debug / solve this? When I'm in the chroot, I can normally change users and all the passwords are accepted, but when I boot normally, nothing works.
I'm really in need for help. This is my primary machine and I would really like to not have to reinstall it.
Thanks in advance!
About this post
- Posted
- Archived
- Score
- 28 · 97% up
- Kind
- Text
- ID
- id6tem
24 comments
Boot live usb, mount root at /mnt or boot single user mode
There was a braking change in pam. This is why you don't ignore the warnings.
I was having this problem too. I knew it had something to do with PAM because last year I was tinkering with setting up an LDAP server, which needs to have its own PAM modules configured.
I wanted to consult the holy powers of Reddit and confirm it was PAM before I booted a live usb to fix it. Thanks for the help.
This is
incorrectnot always correct. I have no pacnew and got no warnings, and am still affected.There are no pacnew files on my computer anymore (because I always take care of merging them) and I can't login.
The culprit is still probably pam and that's all I know about it.
Did you ever figure out what caused the issue?
Thanks for the hint, but unfortunately I don't have a system-auth.pacsave there. All I got is a system-login.pacnew. I'm going to try this now.
Can you point me to the announcement? Normally I would expect something like this to be on the mailing list, but perhaps I just missed it...
Really thanks for pointing me in the right direction, I copied my system-login.pacnew to system-login and now I can login again! Thanks a lot!
There is none, you have done manual changes to
/etc/pam.d/system-loginand pacman warns that it saves a.pacnewfile when you update. This is expected behaviourYou (or a program running on your system) had modified a configuration file. Hence pacman didn't overwrite it, but left the new configuration alongside it in a .pacnew file for you to merge manually. See https://wiki.archlinux.org/index.php/System_maintenance#Deal_promptly_with_new_configuration_files
Deleted before we saved it.
I have the same issue as OP, however there is no
system-login.pacnewin my/etc/pam.dAny idea?
What if I have the same issue but there js no pacsave or pacnew file?
If you can log in as root, try to change user_readenv=1 to user_readenv=0 in /etc/pam.d/system-login. If it works after that change then take a look at your ~/.pam_environment file (modify or remove/move it).
Check the pacman log
/var/log/pacman.logDeleted before we saved it.
Thanks for this, it fixed the problem on my machine.
Note for others, you don't have to boot a live USB, I was able to login as root via the systemd rescue target. Append systemd.unit=rescue.target to you kernel params in the grub menu.
Thank you so much, lots of reboots and arch-chroots before finding this in the update log
Thank you for this. I had the same problem, I also chrooted from a live usb and changed user and root password and still it did not work. I was about to reinstall everything, lol. Thanks!
BTW should I have seen a warning during installation? I probably was not paying attention.
Deleted before we saved it.
Do you see your profile name in the shadow file? Can you log into root with no password?
In case anyone else is an idiot like me, I had this problem, and it turned out it was because one of the .pacnew files I merged was /etc/shadow, so it cleared all the passwords for all my accounts. I had to boot into a flash drive, then change both passwords (user and root) with passwd.