NVIDIA driver problem after switching kernel

After switching from zen to arch kernel, NVIDIA driver is unloaded and not working. I reinstalled the driver also but it didn't solve the problem. Please help me regarding this!

prime-run nvidia-settings output :

ERROR: NVIDIA driver is not loaded


(nvidia-settings:9485): GLib-GObject-CRITICAL **: 21:57:14.328: g_object_unref: assertion 'G_IS_OBJECT (object)' failed

** (nvidia-settings:9485): CRITICAL **: 21:57:14.329: ctk_powermode_new: assertion '(ctrl_target != NULL) && (ctrl_target->h != NULL)' failed

ERROR: nvidia-settings could not find the registry key file or the X server is not accessible. This file should have been installed along with this driver at
       /usr/share/nvidia/nvidia-application-profiles-key-documentation. The application profiles will continue to work, but values cannot be prepopulated or validated, and
       will not be listed in the help text. Please see the README for possible values and descriptions.

garuda-inxi output :

System:
  Kernel: 5.16.14-arch1-1 x86_64 bits: 64 compiler: gcc v: 11.2.0
    parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux
    root=UUID=48bcd8f8-8b3f-4880-b42a-006b8a79a3d7 rw [email protected]
    quiet quiet splash rd.udev.log_priority=3 vt.global_cursor_default=0
    resume=UUID=7a1e7bea-7a5f-4dbe-b369-1f62294f03e1 loglevel=3
  Desktop: GNOME 41.4 tk: GTK 3.24.33 wm: gnome-shell dm: GDM 41.3
    Distro: Garuda Linux base: Arch Linux
Machine:
  Type: Laptop System: HP product: HP Pavilion Gaming Laptop 15-ec2xxx v: N/A
    serial: <filter> Chassis: type: 10 serial: <filter>
  Mobo: HP model: 88DE v: 96.31 serial: <filter> UEFI: AMI v: F.15
    date: 08/18/2021
Battery:
  ID-1: BAT0 charge: 50.3 Wh (99.6%) condition: 50.5/50.5 Wh (100.0%)
    volts: 12.9 min: 11.6 model: HP Primary type: Li-ion serial: <filter>
    status: N/A
CPU:
  Info: model: AMD Ryzen 5 5600H with Radeon Graphics socket: FP6 bits: 64
    type: MT MCP arch: Zen 3 family: 0x19 (25) model-id: 0x50 (80) stepping: 0
    microcode: 0xA50000C
  Topology: cpus: 1x cores: 6 tpc: 2 threads: 12 smt: enabled cache:
    L1: 384 KiB desc: d-6x32 KiB; i-6x32 KiB L2: 3 MiB desc: 6x512 KiB
    L3: 16 MiB desc: 1x16 MiB
  Speed (MHz): avg: 1375 high: 3300 min/max: 1200/4280 boost: enabled
    base/boost: 3300/4250 scaling: driver: acpi-cpufreq governor: schedutil
    volts: 1.2 V ext-clock: 100 MHz cores: 1: 1200 2: 1200 3: 3300 4: 1200
    5: 1200 6: 1200 7: 1200 8: 1200 9: 1200 10: 1200 11: 1200 12: 1200
    bogomips: 79075
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm
  Vulnerabilities:
  Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: spec_store_bypass
    mitigation: Speculative Store Bypass disabled via prctl
  Type: spectre_v1
    mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2 mitigation: Retpolines, IBPB: conditional, IBRS_FW,
    STIBP: always-on, RSB filling
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: NVIDIA GA107M [GeForce RTX 3050 Mobile] vendor: Hewlett-Packard
    driver: N/A alternate: nouveau pcie: gen: 3 speed: 8 GT/s lanes: 8
    link-max: gen: 4 speed: 16 GT/s lanes: 16 bus-ID: 01:00.0
    chip-ID: 10de:25a2 class-ID: 0300
  Device-2: AMD Cezanne vendor: Hewlett-Packard driver: amdgpu v: kernel
    pcie: gen: 3 speed: 8 GT/s lanes: 16 link-max: gen: 4 speed: 16 GT/s ports:
    active: eDP-1 empty: none bus-ID: 05:00.0 chip-ID: 1002:1638
    class-ID: 0300
  Device-3: Luxvisions Innotech HP TrueVision HD Camera type: USB
    driver: uvcvideo bus-ID: 3-3:3 chip-ID: 30c9:0035 class-ID: fe01
    serial: <filter>
  Display: server: X.Org v: 1.21.1.3 compositor: gnome-shell driver: X:
    loaded: amdgpu,ati unloaded: modesetting,radeon alternate: fbdev,vesa
    gpu: amdgpu display-ID: :1 screens: 1
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.0x11.2")
    s-diag: 582mm (22.9")
  Monitor-1: eDP res: 1920x1080 hz: 144 dpi: 142
    size: 344x193mm (13.5x7.6") diag: 394mm (15.5")
  OpenGL: renderer: AMD RENOIR (DRM 3.44.0 5.16.14-arch1-1 LLVM 13.0.1)
    v: 4.6 Mesa 21.3.7 direct render: Yes
Audio:
  Device-1: NVIDIA vendor: Hewlett-Packard driver: snd_hda_intel v: kernel
    pcie: speed: Unknown lanes: 63 link-max: gen: 6 speed: 64 GT/s
    bus-ID: 01:00.1 chip-ID: 10de:2291 class-ID: 0403
  Device-2: AMD ACP/ACP3X/ACP6x Audio Coprocessor vendor: Hewlett-Packard
    driver: N/A
    alternate: snd_pci_acp3x, snd_rn_pci_acp3x, snd_pci_acp5x, snd_pci_acp6x
    pcie: gen: 3 speed: 8 GT/s lanes: 16 link-max: gen: 4 speed: 16 GT/s
    bus-ID: 05:00.5 chip-ID: 1022:15e2 class-ID: 0480
  Device-3: AMD Family 17h/19h HD Audio vendor: Hewlett-Packard
    driver: snd_hda_intel v: kernel pcie: gen: 3 speed: 8 GT/s lanes: 16
    link-max: gen: 4 speed: 16 GT/s bus-ID: 05:00.6 chip-ID: 1022:15e3
    class-ID: 0403
  Sound Server-1: ALSA v: k5.16.14-arch1-1 running: yes
  Sound Server-2: PulseAudio v: 15.0 running: no
  Sound Server-3: PipeWire v: 0.3.48 running: yes
Network:
  Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
    vendor: Hewlett-Packard driver: r8169 v: kernel pcie: gen: 1
    speed: 2.5 GT/s lanes: 1 port: e000 bus-ID: 02:00.0 chip-ID: 10ec:8168
    class-ID: 0200
  IF: eno1 state: down mac: <filter>
  Device-2: Realtek RTL8852AE 802.11ax PCIe Wireless Network Adapter
    vendor: Hewlett-Packard driver: rtw89_pci v: kernel pcie: gen: 1
    speed: 2.5 GT/s lanes: 1 port: d000 bus-ID: 03:00.0 chip-ID: 10ec:8852
    class-ID: 0280
  IF: wlo1 state: up mac: <filter>
Bluetooth:
  Device-1: Realtek Bluetooth Radio type: USB driver: btusb v: 0.8
    bus-ID: 1-4:2 chip-ID: 0bda:2852 class-ID: e001 serial: <filter>
  Report: bt-adapter ID: hci0 rfk-id: 0 state: down
    bt-service: enabled,running rfk-block: hardware: no software: yes
    address: <filter>
Drives:
  Local Storage: total: 476.94 GiB used: 42.5 GiB (8.9%)
  SMART Message: Required tool smartctl not installed. Check --recommends
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Micron
    model: MTFDHBA512TDV-1AZ1AABHA size: 476.94 GiB block-size: physical: 512 B
    logical: 512 B speed: 31.6 Gb/s lanes: 4 type: SSD serial: <filter>
    rev: HPS0032 temp: 40.9 C scheme: GPT
Partition:
  ID-1: / raw-size: 151.4 GiB size: 151.4 GiB (100.00%)
    used: 42.5 GiB (28.1%) fs: btrfs block-size: 4096 B dev: /dev/nvme0n1p8
    maj-min: 259:8
  ID-2: /boot/efi raw-size: 615 MiB size: 613.8 MiB (99.80%)
    used: 580 KiB (0.1%) fs: vfat block-size: 512 B dev: /dev/nvme0n1p6
    maj-min: 259:6
  ID-3: /home raw-size: 151.4 GiB size: 151.4 GiB (100.00%)
    used: 42.5 GiB (28.1%) fs: btrfs block-size: 4096 B dev: /dev/nvme0n1p8
    maj-min: 259:8
  ID-4: /var/log raw-size: 151.4 GiB size: 151.4 GiB (100.00%)
    used: 42.5 GiB (28.1%) fs: btrfs block-size: 4096 B dev: /dev/nvme0n1p8
    maj-min: 259:8
  ID-5: /var/tmp raw-size: 151.4 GiB size: 151.4 GiB (100.00%)
    used: 42.5 GiB (28.1%) fs: btrfs block-size: 4096 B dev: /dev/nvme0n1p8
    maj-min: 259:8
Swap:
  Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default)
  ID-1: swap-1 type: partition size: 8 GiB used: 0 KiB (0.0%) priority: -2
    dev: /dev/nvme0n1p7 maj-min: 259:7
  ID-2: swap-2 type: zram size: 7.18 GiB used: 0 KiB (0.0%) priority: 100
    dev: /dev/zram0
Sensors:
  System Temperatures: cpu: 42.0 C mobo: N/A gpu: amdgpu temp: 42.0 C
  Fan Speeds (RPM): cpu: 0 fan-2: 0
Info:
  Processes: 340 Uptime: 48m wakeups: 1 Memory: 7.18 GiB
  used: 1.72 GiB (23.9%) Init: systemd v: 250 tool: systemctl Compilers:
  gcc: 11.2.0 Packages: pacman: 1225 lib: 321 Shell: garuda-inxi (sudo)
  default: Bash v: 5.1.16 running-in: gnome-terminal inxi: 3.3.13
Garuda (2.5.6-2):
  System install date:     2022-03-13
  Last full system update: 2022-03-16
  Is partially upgraded:   No
  Relevant software:       NetworkManager
  Windows dual boot:       Yes
  Snapshots:               Snapper
  Failed units:

How did you do this?

From Garuda settings manager

Also sudo modprobe -v nvidia fails :

modprobe: FATAL: Module nvidia not found in directory /lib/modules/5.16.14-arch1-1

Output of:

sudo pacman -Syu nvidia-dkms
sudo dkms autoinstall

?

3 Likes

Linux and Nvidia are two words that really do not belong in the same sentence, problems often occur with that combination.

Nevertheless, if you still want to pursue running Linux with Nvidia binary blob drivers, do not choose a cutting-edge kernel. Use an LTS kernel, because it has higher compatibility with Nvidia proprietary drivers.

Thanks! Running these 2 commands helped and driver is properly loaded now.

Sure, I will use LTS kernel. But what is the release cycle of LTS kernel compared to arch one?

The kernel release cadence is kind of approximate. There aren't specific release dates, nothing is set in stone.

Speaking in broadly generalized terms, a new Linux kernel gets released every few months. Between new releases, the current kernel will continue to get patches and development, and a kernel gets supported for a few months after the next kernel comes out.

The LTS kernel is more of an annual release, and it continues to get support and development for two years or sometimes more.

In addition to those, there are a hundred other kernels that are derivatives of the Linux kernel, including distro-specific or otherwise custom "spins" (like your arch kernel or the zen kernel, for example). The release cycles related to these kernels are dependent on both the upstream kernel, and also the maintainer of the kernel.

Out of curiosity, why did you choose to switch to that kernel?

2 Likes

Surprisingly my hardware is running faster and smoother on arch kernel than zen kernel. That's why I changed the kernel. No other reason to do so except this.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.