Unable to use Nvidia Quadro

I’m taking Fedora KDE for a spin again.

Everything works out of the box, but I can’t get the NVIDIA graphics card to work

lspci | grep "VGA\|NVIDIA"
00:02.0 VGA compatible controller: Intel Corporation CoffeeLake-H GT2 [UHD Graphics 630]
01:00.0 3D controller: NVIDIA Corporation GP107GLM [Quadro P2000 Mobile] (rev a1)
Operating System: Fedora Linux 38
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.105.0
Qt Version: 5.15.9
Kernel Version: 6.2.14-300.fc38.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 12 × Intel® Core™ i9-8950HK CPU @ 2.90GHz
Memory: 31.0 GiB of RAM
Graphics Processor: Mesa Intel® UHD Graphics 630
Manufacturer: Dell Inc.
Product Name: Precision 5530

I’ve followed the process of manually installing the NVIDIA drivers and although they install, and I can see the NVIDIA X-Server application installed, the system keeps on saying Mesa Intel UHD Graphics.

I then removed it again and followed the akmod-nvidia route which too installs the driver, but I’m unable to switch to it. I used to be able to run sudo prime-select nvidia to switch to the NVIDIA driver.

Any suggestions?

Try lsmod | grep -e 'nvidia|nouveau' to see which drivers are loaded and active.
Use dnf list installed '*nvidia*' to see exactly what packages are installed.
Please post the output of both.

This shows how to make the nvidia GPU p[rimary on laptops. Note that it only works this way when using xorg as your DE.

lsmod | grep -e 'nvidia\|nouveau'
nvidia_drm             94208  1
nvidia_modeset       1290240  1 nvidia_drm
nvidia_uvm           3219456  0
nvidia              55853056  17 nvidia_uvm,nvidia_modeset
video                  77824  4 dell_wmi,dell_laptop,i915,nvidia_modeset
dnf list installed '*nvidia*'
Installed Packages
akmod-nvidia.x86_64                                                                                   3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
kmod-nvidia-6.2.14-300.fc38.x86_64.x86_64                                                             3:530.41.03-1.fc38                                                              @@commandline     
nvidia-gpu-firmware.noarch                                                                            20230404-149.fc38                                                               @updates          
nvidia-settings.x86_64                                                                                3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia.x86_64                                                                            3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-cuda-libs.x86_64                                                                  3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-kmodsrc.x86_64                                                                    3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-libs.x86_64                                                                       3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-power.x86_64                                                                      3:530.41.03-1.fc38                                                              @rpmfusion-nonfree

if I run glxinfo

glxinfo | egrep "OpenGL vendor|OpenGL renderer"
egrep: warning: egrep is obsolescent; using grep -E
OpenGL vendor string: Intel
OpenGL renderer string: Mesa Intel(R) UHD Graphics 630 (CFL GT2)

it still points to the intel card

I have 2 packages installed that you seem to be missing. nvidia-persistenced (not sure what required it or if I installed it separately) and xorg-x11-drv-nvidia-cuda (which provides the cuda software for many uses and makes the nvidia-smi program available.)

Otherwise it seems things are complete and functional and you would only need to set the nvidia gpu as primary per that doc linked above. Then reboot.

One other factor may be the structure of the options in the kernel command line for booting.
Please post cat /proc/cmdline

I’m following that optimus guide to the letter now, let’s see if that works.

In the meantime:

cat /proc/cmdline
BOOT_IMAGE=(hd0,gpt2)/vmlinuz-6.2.14-300.fc38.x86_64 root=UUID=db7e27be-5740-4a5b-a37c-2b586d6aab7c ro rootflags=subvol=root rd.luks.uuid=luks-a3160ba5-ed38-4048-a397-fe001b2aa639 rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau

I have this

$ glxinfo | grep -E "OpenGL vendor|OpenGL renderer"
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: NVIDIA GeForce GTX 1660 Ti/PCIe/SSE2



$ cat /etc/X11/xorg.conf.d/nvidia.conf 
#This file is provided by xorg-x11-drv-nvidia
#Do not edit

Section "OutputClass"
	Identifier "nvidia"
	MatchDriver "nvidia-drm"
	Driver "nvidia"
	Option "AllowEmptyInitialConfiguration"
	Option "SLI" "Auto"
	Option "BaseMosaic" "on"
	Option "PrimaryGPU" "yes"
EndSection

Section "ServerLayout"
	Identifier "layout"
	Option "AllowNVIDIAGPUScreens"
	Option "PrimaryGPU" "yes"
EndSection

and am logged in with the ‘Gnome on xorg’ DE

$ inxi -Gx
Graphics:
  Device-1: Intel CoffeeLake-H GT2 [UHD Graphics 630] vendor: ASUSTeK
    driver: i915 v: kernel arch: Gen-9.5 bus-ID: 00:02.0
  Device-2: NVIDIA TU116M [GeForce GTX 1660 Ti Mobile] vendor: ASUSTeK
    driver: nvidia v: 525.89.02 arch: Turing bus-ID: 01:00.0
  Display: x11 server: X.Org v: 1.20.14 with: Xwayland v: 22.1.8 driver: X:
    loaded: modesetting,nvidia unloaded: fbdev,nouveau,vesa dri: iris
    gpu: i915,nvidia,nvidia-nvswitch resolution: 1: 1920x1080~60Hz
    2: 1920x1080
  API: OpenGL v: 4.6.0 NVIDIA 525.89.02 renderer: NVIDIA GeForce GTX 1660
    Ti/PCIe/SSE2 direct-render: Yes

$ cat /proc/cmdline
BOOT_IMAGE=(hd0,gpt5)/vmlinuz-6.1.15-200.fc37.x86_64 root=/dev/mapper/fedora_laptop-root ro rd.driver.blacklist=nouveau modprobe.blacklist=nouveau nvidia-drm.modeset=1 initcall_blacklist=simpledrm_platform_driver_init rd.lvm.lv=fedora_laptop/root rhgb quiet

Yes, my laptop has not been updated for quite some time. I just got it back from another location today.

Your command line is missing this nvidia-drm.modeset=1 initcall_blacklist=simpledrm_platform_driver_init and the missing modeset option certainly may be part of the issue.

I’ve added those params to grub

cat /proc/cmdline
BOOT_IMAGE=(hd0,gpt2)/vmlinuz-6.2.14-300.fc38.x86_64 root=UUID=db7e27be-5740-4a5b-a37c-2b586d6aab7c ro rootflags=subvol=root rd.driver.blacklist=nouveau modprobe.blacklist=nouveau rd.luks.uuid=luks-a3160ba5-ed38-4048-a397-fe001b2aa639 rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau nvidia-drm.modeset=1 initcall_blacklist=simpledrm_platform_driver_init

and I’ve followed the optimus guide

sudo dnf install gcc kernel-headers kernel-devel akmod-nvidia xorg-x11-drv-nvidia xorg-x11-drv-nvidia-libs xorg-x11-drv-nvidia-libs.i686

set a timer for 10 min, then ran

sudo akmods --force
sudo dracut --force

waited again 5min before rebooting

no change

Please post the output of the following.
inxi -Gax
dnf list installed '*nvidia*'
cat /etc/kernel/cmdline
cat /etc/default/grub
cat /etc/X11/xorg.conf.d/nvidia.conf

inxi -Gax
Graphics:
  Device-1: Intel CoffeeLake-H GT2 [UHD Graphics 630] vendor: Dell
    driver: i915 v: kernel arch: Gen-9.5 process: Intel 14nm built: 2016-20
    ports: active: DP-5,eDP-1 empty: DP-1, DP-2, DP-3, DP-4 bus-ID: 00:02.0
    chip-ID: 8086:3e9b class-ID: 0300
  Device-2: NVIDIA GP107GLM [Quadro P2000 Mobile] vendor: Dell
    driver: nvidia v: 530.41.03 alternate: nouveau,nvidia_drm non-free: 530.xx+
    status: current (as of 2023-03) arch: Pascal code: GP10x
    process: TSMC 16nm built: 2016-21 pcie: gen: 1 speed: 2.5 GT/s lanes: 16
    link-max: gen: 3 speed: 8 GT/s bus-ID: 01:00.0 chip-ID: 10de:1cba
    class-ID: 0302
  Device-3: Microdia Integrated_Webcam_HD type: USB driver: uvcvideo
    bus-ID: 1-12:5 chip-ID: 0c45:671d class-ID: 0e02
  Device-4: Logitech C920 PRO HD Webcam type: USB
    driver: snd-usb-audio,uvcvideo bus-ID: 1-5.2.3.1.1.2:20 chip-ID: 046d:08e5
    class-ID: 0102 serial: 363F645F
  Display: wayland server: X.org v: 1.20.14 with: Xwayland v: 22.1.9
    compositor: kwin_wayland driver: X: loaded: modesetting,nvidia
    unloaded: fbdev,vesa alternate: nouveau,nv dri: iris gpu: i915,nvidia
    d-rect: 3840x1080 display-ID: 0
  Monitor-1: DP-5 pos: primary,left res: 1920x1080 size: N/A modes: N/A
  Monitor-2: eDP-1 pos: right res: 1920x1080 size: N/A modes: N/A
  API: OpenGL v: 4.6 Mesa 23.0.3 renderer: Mesa Intel UHD Graphics 630 (CFL
    GT2) direct-render: Yes

dnf list installed '*nvidia*'
Installed Packages
akmod-nvidia.x86_64                                                                                   3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
kmod-nvidia-6.2.14-300.fc38.x86_64.x86_64                                                             3:530.41.03-1.fc38                                                              @@commandline     
nvidia-gpu-firmware.noarch                                                                            20230404-149.fc38                                                               @updates          
nvidia-persistenced.x86_64                                                                            3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
nvidia-settings.x86_64                                                                                3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia.x86_64                                                                            3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-cuda-libs.x86_64                                                                  3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-kmodsrc.x86_64                                                                    3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-libs.i686                                                                         3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-libs.x86_64                                                                       3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
xorg-x11-drv-nvidia-power.x86_64                                                                      3:530.41.03-1.fc38                                                              @rpmfusion-nonfree
cat /etc/kernel/cmdline
root=UUID=db7e27be-5740-4a5b-a37c-2b586d6aab7c ro rootflags=subvol=root rd.driver.blacklist=nouveau modprobe.blacklist=nouveau rd.luks.uuid=luks-a3160ba5-ed38-4048-a397-fe001b2aa639 rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau nvidia-drm.modeset=1 initcall_blacklist=simpledrm_platform_driver_init 
cat /etc/default/grub
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX="rd.driver.blacklist=nouveau modprobe.blacklist=nouveau rd.luks.uuid=luks-a3160ba5-ed38-4048-a397-fe001b2aa639 rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau nvidia-drm.modeset=1 initcall_blacklist=simpledrm_platform_driver_init"
GRUB_DISABLE_RECOVERY="true"
GRUB_ENABLE_BLSCFG=true

and I don’t have a xorg.conf since I’m on Wayland
X11 has scaling issues on my monitors and doesn’t support my trackpad

You are logged in with wayland. As such the instructions given will not work.
If you log out then log back in using xorg it should work properly. Use the gear icon at the lower right corner of the screen where you enter the password for selecting the DE to use.

If unable to use xorg then I don’t have instructions to set nvidia as the main GPU. I recall that notes are somewhere on this forum for using nvidia as primary with wayland, but don’t know exactly where.

You also might want to install the cuda package noted earlier.

logging in with X11 just hangs at a black screen forever.

I’ve tried X11 recently on Kubuntu too and was having scaling issues since my monitor is HD and laptop has a 4k screen and then the trackpad gestures doesn’t work under X11 and then there’s the random lockups that I don’t get under Wayland. But under Wayland, I can’t get the NVidia card working since the new 6+ kernel, under the 5 kernel it was working perfectly

Hello,

I thought this might help, i’m using a nvidia quadro card with fedora for a while now. To make it work, the only way was to follow the RPMFusion packages Howto/NVIDIA - RPM Fusion and since fedora 37, secure boot is automatically configured too Howto/Secure Boot - RPM Fusion

I also had to disable intel GPU drivers on my BIOS and only allow NVIDIA discreet graphics. After doing all this, i followed this post to get the CUDA Packages installed :
https://rpmfusion.org/Howto/CUDA#CUDA_Toolkit

I hope this helps. X11 and Wayland both work with my setup.

I’m unable to disable the Intel graphics, such an option is not available in the BIOS.

I think I’ll just use my system without the NVidia card for a few months and then see if it gets fixed with an update along the way.

Thanks for the ideas and input Sobhi and Jeff