NVIDIA has always been one of the best GPU creators in the market. I personally love NVIDIA for their ultra-optimized products and software that makes gaming a lot easier. If you’re an NVIDIA user, you already know what I mean. For those who are running Linux as their operating system, installing the NVIDIA driver is a must to get the most out of the hardware. Let’s take a look how to install NVIDIA drivers on your Linux distro.
The best option
Depending on your Linux distro, there can be different methods to install the latest NVIDIA driver on your system. However, this is the easiest method of all and offers compatibility with almost all the major Linux systems.
- Download the latest driver for Linux. It’s a .RUN file. Download and save it into “Downloads” directory.
- Now, open a Terminal (CTRL + Alt + X) and run the following commands:
cd ~/Downloads chmod +x NVIDIA-Linux-x86_64-390.42.run ./NVIDIA-Linux-x86_64-390.42.run
Now, the NVIDIA driver should be installed properly.
Installing NVIDIA drivers on Arch Linux is quite simple and easy. Open a terminal & run this command:
sudo pacman -S nvidia
After completing, run the following command to install the latest 32-bit version of the driver (IMPORTANT for playing Steam games).
sudo pacman -S nvidia nvidia-libgl lib32-nvidia-libgl nvidia-settings
Now, enable a “persistence” systemd service so that the latest driver works smoothly. Start the opened file with
sudo sudo systemctl start nvidia-persistenced.service
Installing NVIDIA GPU driver on Fedora can follow many paths, so here’s the shortest and easiest method of all.
- Open a terminal and run the command:
sudo dnf update
- Now, you need to add the following repository inside Fedora’s list. Run this command:
sudo dnf config-manager --add-repo=https://negativo17.org/repos/fedora-nvidia.repo
- Open Software Center, search for “NVIDIA Linux Graphics Driver” and install it.
Ubuntu + Ubuntu-based distros
Ubuntu doesn’t have NVIDIA driver in their default software collection. You have to add it by adding a repository.
- Open a terminal and run the following commands:
sudo add-apt-repository ppa:graphics-drivers/ppa sudo apt update sudo apt upgrade -y
- When the process is complete, run this line to install the latest NVIDIA driver.
sudo apt install nvidia-graphics-drivers-390 nvidia-settings vdpauinfo vulkan libvdpau
Take a note that the latest version, at present, is 390. Depending on the latest release, the number will change. If you’re confused, follow the first method described.
If you’re a Debian user, you already know how things work in here. The latest driver isn’t available through the Stable branch. To obtain the latest one, you have to switch towards Unstable branch.
- Open a terminal.
- Run this command:
sudo nano /etc/apt/sources.list
- In the file, change every “stable”, “wheezy” and other Debian release names to “unstable”. For example, here’s a modified line of the file:
deb http://ftp2.fr.debian.org/debian/ unstable main contrib non-free
Make as many changes available.
- Save the file by pressing CTRL + O.
- Run these commands in the terminal:
sudo apt-get update sudo apt-get dist-upgrade
- Install “aptitude”. It makes drivers easier to install.
sudo apt install aptitude
- Run these commands to complete the installation process.
sudo dpkg --add-architecture i386 sudo aptitude -r install nvidia-kernel-dkms nvidia-settings libgl1-nvidia-glx:i386
- Reboot your system.
For enterprise Linux, OpenSUSE is the best free option. Installing NVIDIA driver on OpenSUSE is a bit difficult task, but not impossible. Just follow the steps properly.
Remove the package “drm-kmp-default”. It usually conflicts with NVIDIA packages. Run the command in the terminal:
sudo zypper rm drm-kmp-default
Add NVIDIA driver repository.
sudo zypper addrepo --refresh http://http.download.nvidia.com/opensuse/leap/42.3 NVIDIA
Install the driver.
sudo zypper install-new-recommends
- Run the following commands:
sudo zypper addrepo --refresh http://http.download.nvidia.com/opensuse/tumbleweed NVIDIA sudo zypper install-new-recommends
After installation is complete, don’t forget to restart your system.
If you’re interested, you can try out some of the best alternatives of LibreOffice.