How To Install Nvidia Drivers on AlmaLinux 8

Install Nvidia Drivers on AlmaLinux 8

In this tutorial, we will show you how to install Nvidia Drivers on AlmaLinux 8. For those of you who didn’t know, Installing NVIDIA drivers on AlmaLinux is an easy task that can be done in less than a minute. Nvidia driver is needed by your NVIDIA Graphics GPU to function with better performance. Some Linux distributions offer the proprietary driver pre-packaged as part of its standard package repository making the entire Nvidia Linux Driver procedure extremely easy to follow.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of the Nvidia Drivers on AlmaLinux 8. You can follow the same instructions for CentOS and Rocky Linux.

Install Nvidia Drivers on AlmaLinux 8

Step 1. First, let’s start by ensuring your system is up-to-date.

sudo dnf update
sudo dnf upgrade
sudo dnf install epel-release
sudo dnf install kernel-devel-$(uname -r) kernel-headers-$(uname -r)

Step 2. Installing Nvidia Drivers on AlmaLinux 8.

Now we add the Nvidia repository to your system:

sudo dnf config-manager --add-repo https://developer.download.nvidia.com/compute/cuda/repos/rhel8/x86_64/cuda-rhel8.repo

Once the repository is added, you can proceed to install the latest Nvidia stable driver using the following command below:

sudo dnf install nvidia-driver nvidia-settings

Optionally you can also install the CUDA drivers:

sudo dnf install cuda-driver

All done. Reboot your system. The Nvidia driver should now be installed on your AlamLinux 8 Desktop:

reboot

After the restart, verify the installation worked by running the following command below:

nvidia-smi

Output:

[[email protected] ~]# nvidia-smi
Fri Sep 17 16:08:46 2021
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 460.80 Driver Version: 460.80 CUDA Version: 11.2 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|===============================+======================+======================|
| 0 GeForce GTX 1650 Off | 00000000:03:00.0 On | N/A |
| 56% 30C P8 N/A / 75W | 408MiB / 3909MiB | 5% Default |
| | | N/A |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=============================================================================|
| 0 N/A N/A 1627 G /usr/lib/xorg/Xorg 181MiB |
| 0 N/A N/A 1772 G /usr/bin/gnome-shell 36MiB |
| 0 N/A N/A 3782 G …lib/vmware/bin/vmware-vmx 8MiB |
| 0 N/A N/A 35908 G …lib/vmware/bin/vmware-vmx 8MiB |
| 0 N/A N/A 81318 G /usr/lib/firefox/firefox 169MiB |
+-----------------------------------------------------------------------------+

Congratulations! You have successfully installed Nvidia Drivers. Thanks for using this tutorial for installing Nvidia Drivers on your AlmaLinux 8 system. For additional help or useful information, we recommend you check the official Nvidia website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!