Installing Nvidia drivers on CentOS 8

Issues related to hardware problems
Post Reply
Nostigex
Posts: 2
Joined: 2020/06/10 00:06:01

Installing Nvidia drivers on CentOS 8

Post by Nostigex » 2020/06/10 00:17:55

Hi, when trying to install the proprietary NVIDIA drivers for my Gigabyte Geforce 1650 SUPER, I get the same error messages as described in this post about CentOS 7:

viewtopic.php?t=70510

Code: Select all

Failed to run `/usr/sbin/dkms build -m nvidia -v 440.02 -k 4.18.0-147.el8.x86_64`: Error! echo
Your kernel headers for kernel 4.18.0-147.el8.x86_64 cannot be found at 
/lib/modules/4.18.0-147.el8.x86_64/build or
/lib/modules/4.18.0-147.el8.x86_64/source
You can use the --kernelsourcedir option to tell DKMS where it's located.
I tried pointing dkms to the /lib/modules/4.18.0-147.el8.x86_64/ (which in fact exists, and with a "source" file) directory manually using --kernelsourcedir, but it still can't find the files.

I added ElRepo as advised by TrevorH, but the package manager can't seem to find nvidia-detect. What's my next step?

User avatar
TrevorH
Forum Moderator
Posts: 28827
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Installing Nvidia drivers on CentOS 8

Post by TrevorH » 2020/06/10 01:01:45

Run yum update and then reboot into the new kernel.
CentOS 6 will die in November 2020 - migrate sooner rather than later!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

Nostigex
Posts: 2
Joined: 2020/06/10 00:06:01

Re: Installing Nvidia drivers on CentOS 8

Post by Nostigex » 2020/06/10 14:16:16

Ok, I got the drivers installed successfully. Next issue is that now after selecting CentOS from Grub (I'm dual booting with Debian) it hangs on displaying a single underscore in the upper left corner of the screen and the display itself flickers on and off. Same thing when trying to boot into recovery mode, just with more text that's difficult to make out due to the screen flickering on and off.

User avatar
TrevorH
Forum Moderator
Posts: 28827
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Installing Nvidia drivers on CentOS 8

Post by TrevorH » 2020/06/10 14:18:01

Remove rhgb quiet from the kernel command line at the grub prompt and see if that helps.
CentOS 6 will die in November 2020 - migrate sooner rather than later!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

organicchemistry_01
Posts: 32
Joined: 2017/08/27 09:48:47

Re: Installing Nvidia drivers on CentOS 8

Post by organicchemistry_01 » 2020/06/27 07:14:00

I am running now NVIDIA card, simply dont install dkms if that is the case, you will still get the driver regardless

But if you are desperate, check the headers match your kernel version. Sometimes, when the header is not install along with your kernel, then you do install it at latter time, the system will offer a header that is not match with kernel.

Post Reply

Return to “CentOS 8 - Hardware Support”