0

I have tried all solutions on various forum. Currently, I'm at my wits end to disable the Nouveau driver and install Nvidia drivers. I have tried purging/removing previous Nvidia, blacklist files etc. but I am unable to disable nouveau.

Out put of the lspci -vnn | grep -i VGA -A 12

lspci: Unable to load libkmod resources: error -12
02:00.0 VGA compatible controller [0300]: NVIDIA Corporation GM107GL [Quadro K620] [10de:13bb] (rev a2) (prog-if 00 [VGA controller])
    Subsystem: Hewlett-Packard Company GM107GL [Quadro K620] [103c:1098]
    Physical Slot: 2
    Flags: bus master, fast devsel, latency 0, IRQ 30
    Memory at f2000000 (32-bit, non-prefetchable) [size=16M]
    Memory at e0000000 (64-bit, prefetchable) [size=256M]
    Memory at f0000000 (64-bit, prefetchable) [size=32M]
    I/O ports at 1000 [size=128]
    Expansion ROM at f3080000 [disabled] [size=512K]
    Capabilities: <access denied>
    Kernel driver in use: nouveau

02:00.1 Audio device [0403]: NVIDIA Corporation Device [10de:0fbc] (rev a1)

I have also blacklisted nouveau. I have tried installing Nvidia drivers via the deb package and well as downloading from the Nvidia drivers website. I have also updated the intramfs to be pruned by noveau.

Details of my Ubuntu Distribution

Distributor ID: Ubuntu
Description:    Ubuntu 16.04.2 LTS
Release:    16.04
Codename:   xenial

PS - Mu ultimate goal is to install CUDA drivers and toolkit.

  • Did you try adding the NVidia drivers via the software updater/settings button/Additional Drivers tab (and the other software tabs for proprietary software repositories)? – ubfan1 May 26 '17 at 15:48
  • Hi @ubfan1 I don't have access to the GUI on this machine. It's an Ubuntu LXC. – Dexter May 26 '17 at 22:09
0

First make sure you have the restricted repositories enabled. they are in /etc/apt/sources.list, and probably commented out with a #. Delete the # at the beginning of the line. You may have a few like:

deb-src http://archive.ubuntu.com/ubuntu xenial main restricted #Added by software-properties
deb http://us.archive.ubuntu.com/ubuntu/ xenial main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial main universe multiverse restricted #Added by software-properties
deb http://us.archive.ubuntu.com/ubuntu/ xenial-updates main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-updates main universe multiverse restricted #Added by software-properties
deb http://security.ubuntu.com/ubuntu xenial-security main restricted
deb-src http://security.ubuntu.com/ubuntu xenial-security main universe multiverse restricted #Added by software-properties

Then update your package index:

sudo apt-get update

The nvidia 375 pacakges are the ones which are the latest available in the standard repositories, but 381 is available if you want to try -- it fixes some sleep induced artifacts, but is not as well tested.

My setup is a quadro 1000M, and the nvidia 375 packages I have are:

nvidia-375
nvidia-375-dev
nvidia-modprobe
nvidia-opencl-icd-375
nvidia-prime
nvidia-settings

Clean out all the previous nvidia package you installed, and check that there are no blacklist lines for nvidia in any file in /etc/modprobe.d
Install all the above with:

sudo apt-get install nvidia-375 nvidia-375-dev nvidia-modprobe nvidia-opencl-icd-375 nvidia-prime nvidia-settings

Reboot and see if the nvidia driver is being used:

sudo lshw -C video

You should have in /etc/modprobe.d two files, nvidia-375_hybrid.conf and nvidia-375_hybrid.conf which have a lines which blacklist the nouveau driver and remove any alias. Check that no nouveau is in /etc/modules and that there is nothing in /etc/rc.local that loads nouveau. Finally, check the dmesg output, no nouveau should be seen:

dmesg |grep nouveau

The dmesg output for nvidia should look something like:

$ dmesg |fgrep -i nvidia
[    1.145050] nvidia: module license 'NVIDIA' taints kernel.
[    1.150438] nvidia: module verification failed: signature and/or required key missing - tainting kernel
[    1.154278] nvidia 0000:01:00.0: enabling device (0000 -> 0003)
[    1.154407] nvidia-nvlink: Nvlink Core is being initialized, major device number 244
[    1.154417] NVRM: loading NVIDIA UNIX x86_64 Kernel Module  375.39  Tue Jan 31 20:47:00 PST 2017 (using threaded interrupts)
[    1.155859] nvidia-modeset: Loading NVIDIA Kernel Mode Setting Driver for UNIX platforms  375.39  Tue Jan 31 19:41:48 PST 2017
[    1.156840] [drm] [nvidia-drm] [GPU ID 0x00000100] Loading driver
[   14.454118] nvidia-uvm: Loaded the UVM driver in 8 mode, major device number 240
[   35.821752] nvidia-modeset: Allocated GPU:0 (GPU-821d0db5-a56d-9fdf-72cc-d0eab575873a) @ PCI:0000:01:00.0

Finally, lsmod should contain several nvidia modules and no nouveau.


With the nvidia driver installed, you should be able to install the Intel cuda .deb package. with dpkg -i

Then using apt-get install the cuda and cuda-toolkit, those should bring in many other cuda packages.

Read the Intel instructions, adding the CUDA location to your PATH and LD_LIBRARY_PATH
Copy the samples from the cuda install directory to your home or any place you have write permission, so you can run the make to build the samples. Also, I assume you have your g++ installed, and maybe build-essential The gcc should be present by default, and 16.04 has the right versions (5) for the compilers.

  • I have tried the entire process but I am still unable to disable nouveau drivers. – Dexter May 27 '17 at 11:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.