How to install the NVIDIA drivers on CentOS 8 -

The NVIDIA Driver is a program needed for your NVIDIA Graphics GPU to function with better performance. It communicates between your Linux operating system, in this case CentOS 8, and your hardware, the NVIDIA Graphics GPU. The NVIDIA drivers can be installed by using the bash command after stopping the GUI and disabling the nouveau driver by modifying the GRUB boot menu.
This is a companion discussion topic for the original entry at

Very easy tutorial, but…
at every reboot I have to run

systemctl restart systemd-logind

Cause GDM server does not start and go on black screen.


I am running Centos 8 on a lenovo Thinkpad Carbon Extreme
I followed the instructions provided here and made sure I used the nvidia drivers for the card in my laptop and the external monitors started working! I am excited :slight_smile: Problem is now my laptop screen no longer works.
I would appreciate any suggestions.


You have to remove Red Hat Graphical boot from you grub configuration.
“vi /etc/default/grub” search for line “GRUB_CMDLINE_LINUX=” and remove rhgb at the end before “quiet”.

Then run grub2-mkconfig and reboot.

Just an add for people who run UEFI and Secure boot you can follow theses steps to sign Nvidia module.

Else nice post, thanks !

ERROR: Unable to find the kernel source tree for the currently running kernel
I’m still getting this even after the following guide how to fix that :frowning Tested on two difernt computers and no luck. Got stuck with nvidia drivers on centos. any idea?

Hello Everyone!
I have the same problem as Giacomo_D.
NVIDIA 440.82 + 4.18.0-147.8.1.el8_1.x86_64 but always a black screen after login.
Did anyone found a solution to this?
Remove rhgb from grub didn’t help, systemctl restart systemd-logind worked only for a while.
Thanks in advance

Should be pointed out that (as near as I can tell) the drivers do not work with GNOME Wayland. You need to be using a different windowing system to install the drivers.

I actually got it to work for a couple of hours, but a CENTOS update broke it. And it no longer works. I’ve been crawling all over the internet for several days to find a solution and have found no one who has made the NVIDIA drivers function with GNOME Wayland.

If anyone finds otherwise, I’d love the link!