Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This document describes how to install the nvidia kernel module with DKMS support, so a manual rebuild of the nvidia kernel module is no longer required for every new kernel.

...

1. Find the nvidia graphics (video) model number.

$ lspci | grep -i nvidia

An example of what the output looks like (this is just the graphics card line from the output):

01:00.0 VGA compatible controller: NVIDIA Corporation GP107GL [Quadro P600] (rev a1)

2. A google search for 'nvidia linux' finds the nvidia linux download page:

https://www.nvidia.com/object/unix.html

3. Under the "64 bit" section at the top of that page, select  "Latest Long Lived Branch Version".

It currently looks like this:

Linux x86_64/AMD/EM64T
Latest Long Lived Branch Version: 410.78

4. After selecting the latest long lived branch above, then select the "Supported products" tab, and search for the model name/number from step 1 above. 

From the example in step 1, I found "Quadro P600" in the list of supported products. If you cannot find your model number, go back and look under the supported products for the Latest Legacy GPU version.

5. Click download. 

The current link (NON-legacy) from above is (as of 2018-Dec-7):
http://us.download.nvidia.com/XFree86/Linux-x86_64/410.78/NVIDIA-Linux-x86_64-410.78.run

...

$ cd /var/tmp
$ curl -sLO 'http://us.download.nvidia.com/XFree86/Linux-x86_64/410.78/NVIDIA-Linux-x86_64-410.78.run

6. Install the DKMS rpm (this should be automatically available from the EPEL yum repository)

$ sudo yum install dkms

Installing the dkms rpm should also prompt you to install the kernel-devel RPM (as a dependency).  If you already have the kernel-devel RPM installed, you won't get prompted.  The kernel-devel RPM is required for the nvidia kernel module to be built.  DKMS is not supplied or supported by Red Hat.  But packages available in EPEL usually work well with RHEL.

7. You can view the help info (optional) with this command (use -A to view "Advanced help options)

$ /bin/sh ./NVIDIA-Linux-x86_64-[version].run --help
$ /bin/sh ./NVIDIA-Linux-x86_64-[version].run -A

8. Stop the currently running X server by changing to run level 3. 

This is required by the nvidia installer.  This will kick off anyone who is logged in at the video console.  So check to see if anyone is logged in at ":0" which is the video console.  You can use the 'w' command for this.  Here is an example of someone logged in at the video console:

...

If no one is logged in at ":0", or you get the OK to stop the graphical X server, then switch to runlevel 3:

$ sudo init 3

9. Run the installer (this installs and builds without any questions):

$ sudo /bin/sh ./NVIDIA-Linux-x86_64-[version].run --dkms --run-nvidia-xconfig --no-questions

...

$ sudo /bin/sh ./NVIDIA-Linux-x86_64-[version].run

 

10. Next: reboot (or just switch back to run level 5). 

A reboot is optional – but recommended so you can verify that the graphical login (GDM) starts after a reboot.
If you cannot reboot now, just restart GDM by switching back to run level 5.

$ sudo reboot
or
$ sudo init 5

...

 

Additional Information below:

...

The following command will tell you which kernels have the nvidia module installed:

$ find /lib/modules | grep nvidia.ko

...

Verify the nvidia module is being used and the install was successful

...

Look for gdm in the output from the last ps

...

command below

...

.

$ lsmod | grep nvidia
$ ps axuww | grep X
$ ps axuwwf | less

...