[Wayland] After installing Nvidia drivers, screen immediately turns black after logging in with white cursor visible

tldr; After installing the Nvidia drivers in my existing Fedora 39 KDE install, I see the boot animation and my wallpaper, then only a white cursor on a black background.

I made sure my system was fully updated and running the latest kernel before attempting this. Shutdown my PC, switched out my Radeon 6600 XT for a Nvidia RTX 3060. After rebooting, everything was still working (so it seems that there’s no issue with the GPU itself). I followed the instructions provided by RPMFusion Howto/NVIDIA - RPM Fusion to install the Nvidia drivers. Ultimately, what I ran was:

sudo dnf install akmod-nvidia
sudo dnf install xorg-x11-drv-nvidia-cuda

Everything installed successfully. I waited a few minutes as instructed, and then rebooted. I was thinking you only check the modinfo -F version nvidia after you’ve rebooted to make sure the drivers are present, not before it. However this turned out to not matter anyway.

After rebooting a second time, everything seemed like it was booting normally. I saw the Fedora boot animation, followed by the KDE Plasma splash, then my desktop wallpaper. But then the screen flashes black, followed by showing another wallpaper (I have mine set to show a random wallpaper per login, so maybe it’s reloading the session?) then followed by a black screen with my mouse’s cursor in the middle. It’s movable, but there is nothing else, clicking and pressing the Meta key does nothing. I can switch to another terminal with Ctrl+Alt+F3 and run commands fine.

I checked ERROR: NVIDIA driver is not loaded and thought maybe I rebooted before the kernel had finished compiling. So I uninstalled the Nvidia drivers:

sudo dnf remove xorg-x11-drv-nvidia-cuda
sudo dnf remove akmod-nvidia

I rebooted, expecting to get a desktop again but without the Nvidia drivers (I know; this didn’t actually uninstall the drivers, I work this out later). It did the exact same thing, flashing two wallpapers and then black screen with a cursor in the middle. So I reinstalled the drivers again, waited very long and then rebooted. Same result.

I do not have Secure Boot or TPM enabled on my motherboard, and I checked them to make sure.

Running nvidia-settings resulted in a tonne of “CRITICAL” strings. For example:

fedora nvidia-settings
(nvidia-settings:3639): glib-GObject-CRITICAL g_object_unref **: (current time) assertion 'G_IS_OBJECT (object)' failed

Running glxinfo -B:

Error: Unable to open display

Running modinfo -F version nvidia:

550.54.14

A few excerpts from dmesg:

nvidia: loading out-of-tree module taints kernel
nvidia: module verification failed: signature and/or required key missing - tainting kernel
nvidia: nvidia-nvlink NvLink Core is being initialized, major device number 237
nvidia-uvm: uses symbols [...] inheriting taint
nvidia-modeset: Loading Nvidia Kernel Mode Setting Driver for UNIX platforms 550.54.14 Thu Feb 22 01:25:25 UTC 2024
[drm] loading driver [...]
[drm] initialized nvidia drm [...]
nvidia-fallback.service - Fallback to nouveau as nvidia did not load was skipped because of an unmet condition check (ConditionPathExists=!/sys/module/nvidia).

Running lsmod |grep nouveau outputs nothing.

I then ran the “Recover from Nvidia installer” instructions from RPMFusion:

sudo rm -f /usr/lib{,64}/libGL.so.* /usr/lib{,64}/libEGL.so.*
sudo rm -f /usr/lib{,64}/xorg/modules/extensions/libglx.so
sudo dnf reinstall xorg-x11-server-Xorg mesa-libGL mesa-libEGL libglvnd\*
mv /etc/X11/xorg.conf /etc/X11/xorg.conf.saved

and rebooted (the mv command failed, I guess this is because I’m using Wayland not Xorg); this has gotten me back to a functional desktop. To make sure, I reinstalled the Nvidia drivers a third time, and the behaviour remains the same. Any help for getting the Nvidia drivers up and running would be appreciated.

My specs,
Motherboard: Gigabyte B550M K
GPU: ZOTAC Nvidia RTX 3060 OC
CPU: Ryzen 5 5500

Removed radeon, server

What is the output of lsmod | grep -iE "nvidia|nouveau"

If that returns a list of nvidia modules then the nvidia drivers seem to be loading (but still may be corrupt).

In most cases this seems to fix this particular issue and install modules that work properly.

  1. sudo dnf remove kmod-nvidia-* to remove the failing modules
    then
  2. sudo akmods --force to rebuild the modules
    and
  3. reboot to load the newly signed modules.

I reinstalled the drivers and got back to the third TTY.
Output of lsmod | grep -iE "nvidia|nouveau":

nvidia_drm             126976  14
nvidia_modeset        1605632  5 nvidia_drm
nvidia_uvm            6651904  0
nvidia               60362752  1
video                   77824  1 nvidia_modeset

I ran your provided commands and rebuilt the modules successfully. No effect on the issue. I suspect that the problem is just with KDE and/or Wayland, not the drivers themselves.

Checking NVIDIA Proprietary drivers boots up to black screen it mentions that initcall_blacklist=simpledrm_platform_driver_init should be in the boot command. This does not appear to be the case, as when I run cat /proc/cmdline:

BOOT_IMAGE=(blah blah blah) ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau

Unfortunately, adding initcall_blacklist=simpledrm_platform_driver_init to the boot line does not fix the issue.

For testing purposes, I removed the nvidia drivers and got back to a functional desktop. When I tried logging out the Wayland session and logging into the X11 session, the screen remained black for 10 seconds and then kicked me back to the login screen. This is unusual as when I was using the Radeon GPU the X11 session worked fine.

I have confirmed my suspicion. I tried installing the Nvidia drivers again, and this time logging into X11 instead of Wayland, and the drivers are working fine. So the problem is exclusive to Wayland, I’ve updated the title to reflect this. I’d still like to get it working with Wayland though, as X11 has many bugs (software failing to start, non-functional scaling, etc.)

I’m also curious as to why X11 does not work with the nouveau drivers, but it’s not that important to me.

Added wayland

The issue with nouveau is that nouveau is a reverse engineered driver for nvidia devices. This means that developers must wait until a new GPU is released then they must make an attempt to determine how to create a driver that allows the kernel to use the new hardware without any information nor support from the manufacturer.

Not all features of the GPU are supported on any of the cards and newer cards have even more changes that the developers of nouveau have not been able to keep up with. As I understand it the 3XXX and 4XXX series of GPUs are supported very poorly if at all. Developers are caught between the rapid pace of kernel development on one side and new hardware development on the other side.

It seems well known that hardware acceleration of graphics is not supported on any of the nvidia GPUs when using the nouveau drivers.

1 Like

It’s been about a month now, and the issue still occurs. This seems like a bug, but I am not sure who I would be reporting it to. Probably not Nvidia, the drivers themselves are working fine. KDE Plasma, but they wouldn’t have much control over what the OS is doing. Fedora, but they wouldn’t support anything installed from a third-party repo like RPM Fusion. RPM Fusion would assume you’re using the default Gnome desktop, which I’m assuming it works fine there.

So this is more, who would I report it to that’s the least worst option?

I had the same issue, second screen full white but the cursor was showing properly, my GPU is a Geforce 1060 8gb mounted on a thunderbolt card.

I was able to manage to solve the issue with the following:

# dnf remove \*nvidia\*
# dnf install -y akmod-nvidia kernel-devel
# akmods --force
# dracut --force
$ shutdown -r

still have artifacts though because it still nouveau in use

00:02.0 VGA compatible controller [0300]: Intel Corporation Raptor Lake-P [Iris Xe Graphics] [8086:a7a0] (rev 04)
	Subsystem: Framework Computer Inc. Device [f111:0003]
	Kernel driver in use: i915
--
2e:00.0 VGA compatible controller [0300]: NVIDIA Corporation GP106 [GeForce GTX 1060 6GB] [10de:1c03] (rev a1)
	Subsystem: Micro-Star International Co., Ltd. [MSI] Device [1462:3281]
	Kernel driver in use: nouveau

An update to this; Fedora 40 released with changes indicating it would drop X11 and switch wholly to Wayland. I was hesitant but given the situation, I wanted to try updating to see if it would fix this problem. And it did! I upgraded to Fedora 40, and after rebooting I was in a Wayland session in KDE. Great!

Except, it was not so great. As the experience had now become worse than X11 with Nvidia drivers; apps were crashing, icons were missing, and the frame from one second ago would flash on the screen every second; even while playing a full-screen game. These issues in combination made the system pretty unstable. Not a big concern though, I’ll just roll back to Fedora 39, report my findings in a bug report, and wait until it’s either fixed or Fedora 41 comes out. But in doing that… it resulted in the Nvidia drivers flaking out entirely and falling back to nouveau. And nouveau itself was functioning fine before I did any of this, but now for some reason it was stuck in a VGA resolution (800x600 or something close to that) and many apps were refusing to start at all. Removing and reinstalling the Nvidia drivers did nothing to fix this. My operating system had become entirely unusable, probably due to my own actions in trying to upgrade and then irreversibly causing damage by trying to downgrade.

To anyone currently on Fedora 39, I would advise entirely reinstalling Fedora to get Fedora 40 to avoid the missing icons issue. As for me, this whole experience has lead me to believe that the combination of Fedora, KDE and Nvidia graphics are just not meant to be. If any one of those aspects were different, I’m sure it would be a much better experience, but for now I’ll be looking at using another OS.

I have a very similar issue, except that the black screen and white cursor mostly appear after Fedora boot on Wayland and Gnome Classic. On Gnome on Xorg, which I was using before the last updates, I see the overview of all desktops, just like if I was holding a super-key. I can move the cursor with my mouse, but the cursor is shifted and when clicking it will click not the area the cursor was on, but other spots of the auto-started app (Steam in my case). Once I clicked randomly and succeeded to close not only Steam, but also all other auto-started apps (Thunderbird, Joplin). However, I was never able to open SELinux (its orange icon is showing after every boot in on the top right), Software app or Terminal. Launching these apps did not work by using keyboard, neither. PC shutdown was also never working without a hard reset (holding the computer power button). Booting up old kernels made no difference. The issue is holding me away from using Fedora approximately for one month now. I only can use Windows on my dual-boot Lenovo Legion G5 Desktop with Nvidia RTX 3060.

I have the exact same issue. Trying to install nvidia drivers from RPM Fusion on Fedora 40 Sway Atomic (Wayland).

Following the instructions here: Troubleshooting :: Fedora Docs

Driver version: 550.90.07

I’m sad because I was really enjoying this config until I hit this problem.

Wondering now if I should just start from a Universal Blue Nvidia image and install Sway manually.