How to Install Drivers in Ubuntu 2024

Ubuntu is one of the most popular Linux distributions, known for its user-friendly interface and robust performance. However, unlike Windows, Ubuntu may not come pre-installed with all the necessary drivers for your hardware. In this guide, I will walk you through the process of installing drivers in Ubuntu, using both graphical and command-line methods.

Install Drivers in Ubuntu From Software and Updates (GUI Method)

The Software and Updates tool in Ubuntu provides a convenient way to install drivers through a graphical interface. Here’s how you can use this method:

  1. Launch the Software and Updates tool by searching for it in the Ubuntu Dash or by navigating to System Settings > Software and Updates.
  2. In the Software & Updates window, click on the Additional Drivers tab.
  3. Ubuntu will automatically detect and list the available drivers for your hardware. Select the driver you want to install and click on the Apply Changes button.
  4. Ubuntu will download and install the selected driver. You may need to enter your password to authorize the installation.
  5. Once the installation is complete, restart your system for the changes to take effect.

Using the Software and Updates tool is an easy and convenient way to install drivers in Ubuntu, especially for beginners or users who prefer a graphical interface.

Install Drivers in Ubuntu From Terminal (CLI Method)

If you prefer the command-line interface (CLI), Ubuntu provides a robust set of tools to install drivers from the terminal. Here’s how you can use this method:

  1. Open a terminal by pressing Ctrl+Alt+T or by searching for “Terminal” in the Ubuntu Dash.
  2. Update your system’s package lists by running the following command:
    sudo apt update
    
  3. Once the package lists are updated, you can use the apt package manager to search for and install the necessary drivers. For example, to install the NVIDIA driver, you can run the following command:
    sudo apt install nvidia-driver-<version>
    

    Replace <version> with the appropriate version number of the NVIDIA driver you want to install.

  4. Follow the prompts and enter your password when prompted to authorize the installation.
  5. Once the installation is complete, restart your system for the changes to take effect.

Using the terminal to install drivers in Ubuntu provides more control and flexibility, making it ideal for advanced users who are comfortable with the command-line interface.

Install the Latest (Beta) Nvidia Drivers in Ubuntu

If you are an advanced user or a developer who requires the latest features and improvements, you may want to install the latest beta version of Nvidia drivers. Here’s how you can do it:

  1. Open a terminal by pressing Ctrl+Alt+T or by searching for “Terminal” in the Ubuntu Dash.
  2. Add the official Graphics Drivers PPA (Personal Package Archive) repository by running the following command:
    sudo add-apt-repository ppa:graphics-drivers/ppa
    
  3. Update your system’s package lists by running the following command:
    sudo apt update
    
  4. Once the package lists are updated, you can use the apt package manager to search for and install the latest beta version of the Nvidia driver. For example, to install the latest beta version of the NVIDIA driver, you can run the following command:
    sudo apt install nvidia-driver-<version>-beta
    

    Replace <version> with the appropriate version number of the latest beta driver.

  5. Follow the prompts and enter your password when prompted to authorize the installation.
  6. Once the installation is complete, restart your system for the changes to take effect.

Installing the latest beta Nvidia drivers in Ubuntu allows you to take advantage of the latest features and optimizations, but keep in mind that beta versions may not be as stable as the official releases.

Install Nvidia Drivers in Ubuntu Using Official Installer

In some cases, you may need to install the Nvidia drivers directly from the official installer provided by Nvidia. Here’s how you can do it:

  1. Download the official Nvidia driver installer from the Nvidia website. Make sure to choose the correct driver version for your hardware and Ubuntu version.
  2. Open a terminal by pressing Ctrl+Alt+T or by searching for “Terminal” in the Ubuntu Dash.
  3. Navigate to the directory where the downloaded Nvidia driver installer is located. For example, if the installer is in your Downloads folder, you can navigate to it by running the following command:
    cd ~/Downloads
    
  4. Make the installer executable by running the following command:
    chmod +x <installer_filename>
    

    Replace <installer_filename> with the actual name of the Nvidia driver installer file.

  5. Disable the default Nouveau driver by creating a new file in the modprobe.d directory. Run the following command to create the file:
    sudo nano /etc/modprobe.d/blacklist-nouveau.conf
    

    In the file, add the following lines:

    blacklist nouveau
    options nouveau modeset=0
    
  6. Save the file and exit the text editor.
  7. Restart your system and boot into recovery mode by holding down the Shift key during startup.
  8. In the recovery mode menu, select Root – Drop to root shell prompt.
  9. In the root shell, navigate to the directory where the Nvidia driver installer is located.
  10. Run the Nvidia driver installer by running the following command:
    sudo sh <installer_filename>
    

    Replace <installer_filename> with the actual name of the Nvidia driver installer file.

  11. Follow the on-screen prompts to complete the installation.
  12. Once the installation is complete, restart your system for the changes to take effect.

Installing Nvidia drivers using the official installer provides direct control over the installation process and can be useful in situations where the default methods do not work as expected.

Logo