Ubuntu Linux Install Nvidia Driver (Latest Proprietary Driver) nixCraft

I am a new Ubuntu Linux user. My laptop has Nvidia GPU. How do I install Nvidia drivers on Ubuntu Linux 16.04, 18.04, 18.10?

Introduction: Nvidia graphics processing units (GPUs) used for gaming and professional use in offices. Nvidia GPUs used in data centers, visualization, automobile industry, and artificial intelligence. By default X.org X server use nouveau free/libre software drivers for nVidia cards. The nouveau driver generally provides the inferior performance to Nvidia’s proprietary graphics device drivers for gaming and other professional use. This page shows how to install Nvidia GPU drivers on an Ubuntu Linux desktop.

Ubuntu Linux Install Nvidia Driver

The procedure to install proprietary Nvidia GPU Drivers on Ubuntu 16.04 / 17.10, 18.04 / 18.10 is as follows:

  1. Update your system running apt-get command
  2. You can install Nvidia drivers either using GUI or CLI method
  3. Open “Software and Updates” app to install install Nvidia driver using GUI
  4. OR type “sudo apt install nvidia-driver-390” at the CLI
  5. Reboot the computer/laptop to load the drivers
  6. Verify drivers are working

Let us see all commands in details.

Find out information about your GPU

Naturally, you can only install Nvidia driver if you have Nvidia GPU in your system. Type the hwinfo command/lshw command to find out info about your GPU:
$ hwinfo --gfxcard --short
$ sudo lshw -C display
Ubuntu Linux Find Nvidia GPU info

Install Nvidia driver using GUI method on Ubuntu Linux

Press the Super key (Windows key) and type the following in search box:
update manager
Ubuntu software manager to update packages
Click on the Settings button:
Ubuntu Linux Software Updater
Click on the Additional drivers tab:
Ubuntu Linux Install Nvidia Driver using Sofware Manager GUI tool
Choose nvidia-driver-390 (proprietary, tested) and click on the Apple Changes button. You must authenticate yourself to install Nvidia driver on Ubuntu Linux. You must wait for some time as Nvidia driver downloaded and installed from the internet:
Installing Nvdia drivers on Ubuntu Linux
Click on the Close button when done. You must reboot Ubuntu Linux computer to use the driver by typing the following shutdown command:
$ sudo shutdown -r now
$ sudo reboot
Now skip to the driver verification step.

Ubuntu Install Nvidia driver using the CLI method

Open the termial application and search for nvidia drivers using the apt command or apt-get command:
$ apt search nvidia-driver
OR use the apt-cache command to search package:
$ apt-cache search nvidia-driver
apt-get search for Nvidia driver package
Let us install the nvidia-driver-390 package:
$ sudo apt install nvidia-driver-390
Reboot the Linux with help of either reboot or shutdown command:
$ sudo reboot
Now go to the driver verification step.


Open the terminal application and type nvidia-smi to see GPU info and process that are using Nvidia GPU:
$ nvidia-smi
NVIDIA System Management Interface program on Ubuntu
The nvidia-smi command line utility provides monitoring and management capabilities for each of NVIDIA’s Tesla, Quadro, GRID and GeForce devices from Fermi and higher architecture families. You can see running apps on your GPU and GPU temperature.

How do I configure the NVIDIA graphics driver?

The nvidia-settings command start a GUI tool for configuring the NVIDIA graphics driver. This is useful to see all GPU info or configure multiple external screen/monitors connected to your system. Open the terminal and type the following commands:
$ nvidia-settings
If you wish to save settings start it as follows:
$ sudo nvidia-settings
Ubuntu nvidia-settings tool to configure NVIDIA graphics driver

Posted by: Vivek Gite

The author is the creator of nixCraft and a seasoned sysadmin, DevOps engineer, and a trainer for the Linux operating system/Unix shell scripting.

Spread the love

Posted by News Monkey