Sddm fails to launch

Ever since the recent change to nvidia discussed here, sddm fails to launch. I wonder if I need to add an additional specification for my driver. This is my config, which had been working. My card is a GeForce MX330.

{ config, lib, pkgs, ... }:
{

  hardware.graphics = {
    enable = true;
  };

  services.xserver.videoDrivers = ["nvidia"];

  hardware.nvidia = {
    modesetting.enable = true;
    open = false;

    nvidiaSettings = true;

    prime = {
      sync.enable = true;
      intelBusId = "PCI:0:2:0";
      nvidiaBusId = "PCI:1:0:0";
    };

  };
}
1 Like

Couple things:

  • Can you confirm the bus IDs are correct by running nix run github:eclairevoyant/pcids?
  • What’s the error when starting SDDM if any?

The utility confirms the PCI ids. I don’t get an error message. I get a blank screen with a mouse cursor, then back to the console where it left off, without any error message.

I don’t know if this is relevant, but since it never happened to me before I’ll mention it: after I couldn’t launch, I booted into the prior generation. Sddm launched fine, but plasma would not start. Actually, my system was locked because I couldn’t switch to tty. I had to reboot, switch to tty, do a rebuild, reboot, and everything was back to normal. A little harrowing that I couldn’t reboot straight-away into the prior generation, but I expect that part is plasma related, not nvidia related.

I appreciate your help.

Do a journalctl --boot -1 after a reboot in which you can’t sign in.

I got the same issue on unstable recently with an AMD card. sddm-greeter-qt crashes. I have just returned to a previous version at the moment as I have a number of issues stemming from recent updates so I don’t have any more info or a fix for you…

That sounds the same but my card is Intel. I’m holding off upgrading until I have time to deal with it.

Should be easy to at least tell what’s going wrong if either of you boot it in a broken state once, and then share the logs of journalctl --boot -1 (i.e., the previous boot). Without knowing what’s going wrong it’s not that certain that it’ll be magically fixed.

I saw the earlier message and will do this really soon. Just need to work with and not on my computer for a while. I’ve got some deadlines. Thanks.

1 Like

Had a minute to do this. Should I attach the full journal or post it? It’s very long, but I may miss the important bits. Things seem to get a little hairy around line 1500 with

Sep 03 12:37:28 nixos kernel: r8169 0000:02:00.0 enp2s0: Link is Up - 1Gbps/Full - flow control off
Sep 03 12:37:28 nixos systemd[1]: systemd-rfkill.service: Deactivated successfully.
Sep 03 12:37:28 nixos kernel: snd_hda_codec_hdmi ehdaudio0D2: HDMI: audio coding type 0 not expected
Sep 03 12:37:29 nixos sddm-greeter-qt6[1371]: No shell integration named "layer-shell" found
Sep 03 12:37:29 nixos sddm-greeter-qt6[1371]: Loading shell integration failed.
Sep 03 12:37:29 nixos sddm-greeter-qt6[1371]: Attempted to load the following shells QList("layer-shell")
Sep 03 12:37:29 nixos sddm-helper-start-wayland[1358]: "Fontconfig error: \"/etc/fonts/fonts.conf\", line 5: not well-formed (invalid token)\nFontconfig error: Cannot load config file from /etc/fonts/fonts.conf\n"
Sep 03 12:37:29 nixos sddm-greeter-qt6[1371]: Could not load the Qt platform plugin "wayland" in "" even though it was found.
Sep 03 12:37:29 nixos sddm-greeter-qt6[1371]: This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
                                              
                                              Available platform plugins are: offscreen, minimalegl, eglfs, linuxfb, xcb, vnc, vkkhrdisplay, minimal, wayland-egl, wayland.
Sep 03 12:37:29 nixos systemd-coredump[1435]: Process 1371 (sddm-greeter-qt) of user 175 terminated abnormally with signal 6/ABRT, processing...
Sep 03 12:37:29 nixos systemd[1]: Created slice Slice /system/drkonqi-coredump-processor.
Sep 03 12:37:29 nixos systemd[1]: Created slice Slice /system/systemd-coredump.
Sep 03 12:37:29 nixos systemd[1]: Started Process Core Dump (PID 1435/UID 0).
Sep 03 12:37:29 nixos systemd[1]: Started Pass systemd-coredump journal entries to relevant user for potential DrKonqi handling.

It could be wayland-related, and nvidia a red herring. (I actually don’t see an option to upload the whole journal.)

Has anyone made this work yet? I rolled back my flake.lock and the issue “went away”, but of course that causes other challenges. I did an update on September 8 and the issue came back so any changes in the meantime have not made a difference. If no-one has managed to fix I will try and get some more information over the weekend.

I just got back from traveling for a week with spotty internet access, so no new info here. I just rebuilt, hoping the problem had been fixed. Alas, no. Have you tried with a different display manager? sddm is nice but I don’t really care, so if that is indeed the problem… When I get caught up on other things I’ll mess about with it.

Can you share your sddm config?

Also, just searching for that error: [SOLVED] KDE wayland stucks after starting / Newbie Corner / Arch Linux Forums

Are y’all setting that QT env var that’s supposed to set every QT application to wayland that’s floating around on the hyprland wiki, but not using the wayland setting for sddm?

My config is about as basic as it gets…

  services.displayManager.sddm = {
    enable = true;
    theme = "sddm-chili-theme";
    wayland.enable = true;
  };

I didn’t look at the Arch forum article. (Do I actually need the wayland.enable setting? I just assumed I did but I don’t really know what it does for me.) What is the QT env var? I don’t use hyprland, so is it still relevant?

I have a feeling nvidia might be relevant so, fwiw, my card is GeForce MX330 which, according to nvidia, should be using the 560.35.03 driver.

You only need it if you want to run the wayland version of sddm. The setting is necessary for that, but for the sake of argument, does it work if you disable that?

Only if you want to force QT applications to run as wayland clients. The env var is QT_QPA_PLATFORM=wayland, people often set it unconditionally when they run wayland, and there are tons of instructions telling people to set it (especially on nvidia, because it prevents that annoying flickering on some driver versions/cards), so I wondered if that’s in your environment.variables and causing issues for an sddm that’s not supposed to run on wayland. Clearly not, though.

I don’t think so, sddm is very clearly crashing because of some misconfiguration causing QT not to be able to run as a wayland client.

Another related thread here from upstream: sddm-greeter-qt6 is core dumping on 0.21 · Issue #1875 · sddm/sddm · GitHub

I have no idea how sddm themes work, but I suppose you are configuring one. Is your theme a qt5 theme?

Indeed, disabling wayland for sddm worked.

I wonder if this is why I could never get hyprland to work. If I am using plasma with kwin/wayland, would this still be good to set?

TBH I don’t either, and my greeter is ugly. I would like to figure it out, but it is low down on my priority list. As long as I can log in, I’m good.

I always appreciate your help, TLATER. Thank you.

At this point if something isn’t running its wayland client by default there’s probably a reason, so I wouldn’t suggest it unless you’re annoyed by a specific application flickering, and then you should only enable it for that.

The latest nvidia driver finally has explicit sync anyway, and plasma implemented it, so AIUI as long as your software is up-to-date defaults should be fine on nvidia these days.

Thanks - setting wayland.enable to false sorted it for me. Over a month of angst without being able to update for such a simple setting!

Updating hasn’t sorted out my other issue, but baby steps…

It would still be nice to know what the underlying issue is, if e.g. both of you are using an outdated theme, and ideally fix that instead of side-stepping the issue. Wayland has lots of niceties if you are able to use it, between better scaling functionality and much better multi-screen support. Y’know, stuff you expect from modern computers that Xorg didn’t even know would exist when it was first designed.

But good to know you’re at least in a spot where you can use stuff reasonably again.

I originally used the breeze theme as it was the default, but due to errors with kirigami that I couldn’t resolve, I moved to the chili-theme - or at least I thought I had. Trying to check for you I am no longer convinced…if you can give me a suggested theme or 2 and a way to check I am actually running it I am happy to try some tests…I’d rather the issue go away rather than be dodged!