NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
18.13k stars 14.17k forks source link

Sometimes I can’t log in (to xfce screenlocker or shell) #256665

Open novoid opened 1 year ago

novoid commented 1 year ago

Describe the bug

When using my system (NixOS 23.05, HM, flakes, xfce) I do have the issue that sometimes my log-in attempts are declined despite entering the password correctly.

Steps To Reproduce

  1. lock the screen (= activate xfce4 screen lock app directly or indirectly via suspend/hibernate + resume)
  2. enter password
  3. get feedback for incorrect username/password (although user/pass are correct)

Furthermore:

  1. lock the screen (directly or indirectly via suspend/hibernate + resume)
  2. enter password
  3. get feedback for incorrect username/password (although user/pass are correct)
  4. optionally switch to text console via Alt-F1
  5. enter username
  6. enter password
  7. fail to log-in as well

Then wait for minutes and re-try. Most of the time, after a while log-in is possible.

However, I also got the situation where waiting for 30min didn't solve the issue. A following hibernation + resume and further 30min waiting time didn't help either. I had to shut down + reboot in order to be able to use NixOS again.

Expected behavior

Log-in works every time as long as the correct password is entered.

Screenshots

N/A

Additional context

There's no caps lock issue because I remap caps-lock to control. Furthermore, I switched to the terminal via Alt-F1 and typed the password for testing purposes in the username field as well: all perfect.

While testing the text console, I found out that even there, I can't log in. So it's not just a xfce4 screenlocker issue.

After a while (I can't say the duration follows a pattern) I can log in without an issue. So I need to wait and re-try every minute or so. That's really annoying and a no-go for my business machine.

I've collected several outputs from "journalctl -d":

https://paste.grml.org/3628/ You have to ignore the USB messages as I was switching to a different host via my USB switcher, therefore it's a bit messy.

The failed login attempts after resuming from hibernation start with 11:31:27.

https://paste.grml.org/3629/ is much cleaner: lid closed, thus screen locked and shortly after unlock with bad luck.

12:49:46 lid was closed and opened (which locks the screen) and then login attempts were failing.

Both examples don't seem to show any log message on positive login (at the end).

https://paste.grml.org/3630/ is a NEGATIVE example: lid closing, screen lock and NO issue when entering password

My XDG_RUNTIME_DIR (mentioned on several pages like that) is set to "/run/user/1000". So this seems to be OK.

Notify maintainers

So far, I have no clue what part of my system is causing the issue.

Metadata

Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.

[user@system:~]$ nix-shell -p nix-info --run "nix-info -m"
these 9 paths will be fetched (51.03 MiB download, 231.89 MiB unpacked):
  /nix/store/0jmdsgfnd6aakxdr0sl5l7zzfs59hdrw-stdenv-linux
  /nix/store/3p3vb64fwafh1kwlzp0svjninsnlx3ch-expand-response-params
  /nix/store/4ccwc439gkpk91gflh6zsyx12fkfcggx-patchelf-0.15.0
  /nix/store/9n9gjvzci75gp2sh1c4rh626dhizqynl-binutils-2.39
  /nix/store/cgbpv0vvz31qayvbf3bif2iznp46wcgl-gnumake-4.3
  /nix/store/cmnq5bja0h0an1k3cyb36blkfci8nxaf-file-5.43
  /nix/store/l5i2w0w446pqsnpdxrlsf3azy5aspfxq-binutils-wrapper-2.39
  /nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0
  /nix/store/y372k7srz9jm7v9sv2cs84g3crz27z1s-gcc-wrapper-11.3.0
copying path '/nix/store/3p3vb64fwafh1kwlzp0svjninsnlx3ch-expand-response-params' from 'https://cache.nixos.org'...
copying path '/nix/store/cmnq5bja0h0an1k3cyb36blkfci8nxaf-file-5.43' from 'https://cache.nixos.org'...
copying path '/nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0' from 'https://cache.nixos.org'...
copying path '/nix/store/cgbpv0vvz31qayvbf3bif2iznp46wcgl-gnumake-4.3' from 'https://cache.nixos.org'...
copying path '/nix/store/4ccwc439gkpk91gflh6zsyx12fkfcggx-patchelf-0.15.0' from 'https://cache.nixos.org'...
copying path '/nix/store/9n9gjvzci75gp2sh1c4rh626dhizqynl-binutils-2.39' from 'https://cache.nixos.org'...
copying path '/nix/store/l5i2w0w446pqsnpdxrlsf3azy5aspfxq-binutils-wrapper-2.39' from 'https://cache.nixos.org'...
copying path '/nix/store/y372k7srz9jm7v9sv2cs84g3crz27z1s-gcc-wrapper-11.3.0' from 'https://cache.nixos.org'...
copying path '/nix/store/0jmdsgfnd6aakxdr0sl5l7zzfs59hdrw-stdenv-linux' from 'https://cache.nixos.org'...
 - system: `"x86_64-linux"`
 - host os: `Linux 6.1.52, NixOS, 23.05 (Stoat), 23.05.20230915.360a7d3`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.13.5`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`
nixos-discourse commented 1 year ago

This issue has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/sometimes-i-cant-log-in-to-xfce-screenlocker-or-shell/33155/5

novoid commented 1 year ago

The issue has also been briefly described on reddit: https://www.reddit.com/r/NixOS/comments/16l5xp7/how_to_report_nix_issues/

As of now, no relevant details there.