TransWikia.com

Why does nvidia driver 346 work while driver 384 doesn't

Ask Ubuntu Asked by sayanel on November 19, 2021

I have been trying to upgrade my driver from nvidia-346 to nvidia-384, but the second fails to launch X server.

Computer : Laptop MSI GE60 2PE Apache Pro
CPU : Intel I5-4200H
GPU : GeForce GTX 860M
System : Linux Mint 17.2 64bits
Linux core : 3.16.0-38-generic

Prime is supported, using nvidia-settings to force nvidia gpu use.

For switching from driver 346 (which works fine) to driver 384, I did :

sudo apt-get remove --purge nvidia-*
sudo reboot
sudo apt-get install nvidia-384

(If I install nvidia-346, everything works fine… but I would like to upgrade my driver)

Then I get the mint logo on boot, but end with a black screen. Virtual terminal ctrl+alf+f1 still working.

From there, I ran a few diagnosis :

sudo ubuntu-drivers devices
== /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0 ==
vendor   : NVIDIA Corporation
modalias : pci:v000010DEd00001392sv00001462sd00001107bc03sc02i00
driver   : nvidia-346 - third-party non-free
driver   : xserver-xorg-video-nouveau - distro free builtin
driver   : nvidia-375 - third-party free
driver   : nvidia-381 - third-party free
driver   : nvidia-340 - third-party free
driver   : nvidia-384 - third-party free recommended
driver   : nvidia-378 - third-party free

lspci | grep -i vga
00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06)

sudo lshw -C display
  *-display
       description: 3D controller
       produit: GM107M [GeForce GTX 860M]
       fabriquant: NVIDIA Corporation
       identifiant matériel: 0
       information bus: pci@0000:01:00.0
       version: a2
       bits: 64 bits
       horloge: 33MHz
       fonctionnalités: pm msi pciexpress bus_master cap_list rom
       configuration: driver=nvidia latency=0
       ressources: irq:52 mémoire:f6000000-f6ffffff mémoire:e0000000-efffffff mémoire:f0000000-f1ffffff portE/S:e000(taille=128) mémoire:f7000000-f707ffff
  *-display
       description: VGA compatible controller
       produit: 4th Gen Core Processor Integrated Graphics Controller
       fabriquant: Intel Corporation
       identifiant matériel: 2
       information bus: pci@0000:00:02.0
       version: 06
       bits: 64 bits
       horloge: 33MHz
       fonctionnalités: msi pm vga_controller bus_master cap_list rom
       configuration: driver=i915 latency=0
       ressources: irq:46 mémoire:f7400000-f77fffff mémoire:d0000000-dfffffff portE/S:f000(taille=64)

sudo nvidia-detector
none

inxi -SGx
System:   Host: Deepthought Kernel: 3.16.0-38-generic x86_64 (64 bit, gcc: 4.8.2)
          Console: tty 1 Distro: Linux Mint 17.2 Rafaela
Graphics: Card: Intel 4th Gen Core Processor Integrated Graphics Controller bus-ID: 00:02.0
          X.org: 1.15.1 drivers: nvidia,intel tty size: 240x67 Advanced Data: N/A for root out of X

Here is the /var/log/Xorg.0.log file : https://pastebin.com/ZDa3GgpX

The log in /var/log/gpu-manager.log : https://pastebin.com/RYgAuqST

I also ran these command :

dpkg -l | grep -i nvidia

ii  bbswitch-dkms                                         0.7-2ubuntu1                                        amd64        Interface for toggling the power on nVidia Optimus video cards
rc  libcuda1-352-updates                                  352.63-0ubuntu0.14.04.1                             amd64        NVIDIA CUDA runtime library
rc  libcuda1-361                                          361.45.18-0ubuntu0~gpu14.04.1                       amd64        NVIDIA CUDA runtime library
rc  libcuda1-364                                          364.19-0ubuntu0~gpu14.04.3                          amd64        NVIDIA CUDA runtime library
rc  libcuda1-367                                          367.44-0ubuntu0~gpu14.04.1                          amd64        NVIDIA CUDA runtime library
rc  libcuda1-370                                          370.28-0ubuntu0~gpu14.04.1                          amd64        NVIDIA CUDA runtime library
rc  libcuda1-384                                          384.69-0ubuntu0~gpu14.04.1                          amd64        NVIDIA CUDA runtime library
ii  nvidia-384                                            384.69-0ubuntu0~gpu14.04.1                          amd64        NVIDIA binary driver - version 384.69
ii  nvidia-prime                                          0.6.2.1linuxmint1                                   amd64        Tools to enable NVIDIA's Prime
ii  nvidia-settings                                       346.72-0ubuntu1                                     amd64        Tool for configuring the NVIDIA graphics driver

dmesg | egrep -i “bbswitch|nvidia”

[   17.368801] nvidia: module license 'NVIDIA' taints kernel.
[   17.372095] nvidia: module verification failed: signature and/or  required key missing - tainting kernel
[   17.376643] nvidia-nvlink: Nvlink Core is being initialized, major device number 249
[   17.376921] NVRM: loading NVIDIA UNIX x86_64 Kernel Module  384.69  Wed Aug 16 19:34:54 PDT 2017 (using threaded interrupts)
[   17.377929] nvidia-modeset: Loading NVIDIA Kernel Mode Setting Driver for UNIX platforms  384.69  Wed Aug 16 19:39:44 PDT 2017
[   17.378275] [drm] [nvidia-drm] [GPU ID 0x00000100] Loading driver
[   17.408885] nvidia-uvm: Loaded the UVM driver in 8 mode, major device number 248
[   18.071894] nvidia 0000:01:00.0: irq 51 for MSI/MSI-X
[   18.072250] systemd-udevd[805]: failed to execute '/bin/systemctl' '/bin/systemctl start --no-block nvidia-persistenced.service': No such file or directory
[   21.215643] bbswitch: version 0.7
[   21.215649] bbswitch: Found integrated VGA device 0000:00:02.0: _SB_.PCI0.GFX0
[   21.215655] bbswitch: Found discrete VGA device 0000:01:00.0: _SB_.PCI0.PEG0.PEGP
[   21.215730] bbswitch: detected an Optimus _DSM function
[   21.215735] bbswitch: Succesfully loaded. Discrete card 0000:01:00.0 is on
[   21.387726] systemd-udevd[1211]: failed to execute '/bin/systemctl' '/bin/systemctl stop --no-block nvidia-persistenced': No such file or directory
[   23.363834] nvidia 0000:01:00.0: irq 52 for MSI/MSI-X
[   23.560676] nvidia-modeset: Allocated GPU:0 (GPU-73945cf4-306b-7a4c-199c-65624530c4a3) @ PCI:0000:01:00.0
[   23.560775] nvidia-modeset: Freed GPU:0 (GPU-73945cf4-306b-7a4c-199c-65624530c4a3) @ PCI:0000:01:00.0

And this is the content of the /lib/module/3.16.0-38-generic/kernel/drivers/drm folder :

nvidia_384_drm.ko
nvidia_384.ko
nvidia_384_modeset.ko
nvidia_384_uvm.ko

I also have a /etc/modprobe.d/nvidia-graphic-drivers.conf containing :

# This file was installed by nvidia-384
# Do not edit this file manually

blacklist nouveau
blacklist lbm-nouveau
blacklist nvidia-current
blacklist nvidia-173
blacklist nvidia-96
blacklist nvidia-current-updates
blacklist nvidia-173-updates
blacklist nvidia-96-updates
blacklist nvidia-384-updates
alias nvidia nvidia_384
alias nvidia-uvm nvidia_384_uvm
alias nvidia-modeset nvidia_384_modeset
alias nvidia-drm nvidia_384_drm
alias nouveau off
alias lbm-nouveau off

options nvidia_384_drm modeset=0

I hope this is enough for someone to help me ?
Thanks

One Answer

Per OP's comment, installing a later kernel helped (the 4.4, linux-generic-lts-xenial package).

Hence this is a Ubuntu packaging bug which I'd recommend to report. They should add a later kernel to dependencies of NVidia-384 (4.4 will surely do the work).

Ultimately, kernel have no stable interface for working with modules, which is on purpose — it's one of reasons that despite being 26 years old it is still being modern and well developed. It is being refactored in and out every time, internal interfaces being dropped, added, rewritten, improved, etc.

It's good, and is in fact desirable for card manufacturers with drivers in kernel (e.g. Intel and AMD). But NVidia for political reasons keeps the code closed, instead they're using DKMS to work with the internal unstable API. And in your case what apparently happened is some breaking change on the way from 3.16 to 4.4, which caused the NVidia kernel driver to fail.

FTR, please note the distinction between kernel GPU drivers (which I'm talking about) and userspace GPU drivers (being a component to kernel ones).

Also FYI, 3.16 is not old, because 4.4 is. 3.16 is ancient.

Answered by Hi-Angel on November 19, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP