Ubuntu-drivers command not found? Resolve the issue quickly
In this article
The Ubuntu-drivers command is missing because the ubuntu-drivers-common package that provides it is not installed or the system’s PATH is misconfigured. Installing the package or correcting the PATH restores the command.
Background: What Ubuntu‑drivers Is
Ubuntu‑drivers is a wrapper script that queries the Ubuntu Hardware Enablement stack for proprietary or open‑source drivers. It is part of the ubuntu-drivers-common package, which ships with most Ubuntu installations but can be omitted on minimal or server installs to save disk space. The script simplifies driver installation by automatically selecting the most appropriate driver for your hardware, especially for NVIDIA, AMD, and Intel GPUs, as well as Wi‑Fi and Bluetooth adapters.
How the Command Works
The script performs three main actions:
- Detects all hardware devices that may need drivers.
- Queries the Ubuntu repositories for candidate drivers and ranks them by recommendation level.
- Installs, removes, or lists drivers based on user options.
When you run ubuntu-drivers devices, the script parses /var/lib/ubuntu-drivers/ and /usr/share/ubuntu-drivers/ to build a table of available drivers. It then prints a short summary that looks like this:
$ ubuntu-drivers devices
== Add/Remove Drivers ==
Device: Intel(R) UHD Graphics 620
Driver: xserver-xorg-video-intel
Device: NVIDIA GeForce GTX 1050
Driver: nvidia-driver-535
Running ubuntu-drivers autoinstall installs the highest‑ranked driver for each device, while ubuntu-drivers list shows all candidates without installing.
Choosing the Right Driver
Ubuntu categorizes drivers by recommendation level:
- Recommended – the most stable and well‑tested driver for your hardware.
- Enabled – a driver that works but may lack some features or be less stable.
- Available – drivers that can be installed but are not officially recommended.
For GPUs, the “recommended” driver is usually the latest Long Term Support (LTS) version. For example, an NVIDIA GTX 1050 will often show nvidia-driver-535 as recommended, while nvidia-driver-525 appears as available. Choosing a non‑recommended driver can lead to crashes or reduced performance.
Common Problems and Fixes
Below are frequent reasons why ubuntu-drivers is not found and how to resolve them.
- Package not installed
- Minimal or server images omit
ubuntu-drivers-common. Install it withsudo apt update && sudo apt install ubuntu-drivers-common.
- Minimal or server images omit
- Broken or missing PATH
- Verify that
/usr/binis in$PATHby runningecho $PATH. If missing, addexport PATH=$PATH:/usr/binto your shell profile.
- Verify that
- Corrupted installation
- Reinstall the package:
sudo apt reinstall ubuntu-drivers-common.
- Reinstall the package:
- Using an unsupported Ubuntu release
- Older releases may not have the script. Upgrade to a supported LTS or use
apt-get install ubuntu-drivers-commonfrom a newer release’s repository.
- Older releases may not have the script. Upgrade to a supported LTS or use
- Conflicting driver packages
- If you manually installed a driver from a PPA, remove it before running
ubuntu-drivers autoinstallto avoid conflicts.
- If you manually installed a driver from a PPA, remove it before running
Alternatives to Ubuntu‑drivers
While ubuntu-drivers is convenient, other methods exist:
- Software & Updates – the graphical utility that lists drivers under the “Additional Drivers” tab.
- Direct apt commands – e.g.,
sudo apt install nvidia-driver-535for NVIDIA GPUs. - Hardware‑specific tools – NVIDIA’s
nvidia-smiandnvidia-settings, AMD’samdgpu-proinstaller, or Intel’sintel-microcode. - Third‑party PPAs – for bleeding‑edge drivers, but they can break updates.
Choosing an alternative is often a matter of preference or specific hardware support.
Safety and Best Practices
Driver installation can affect system stability. Follow these guidelines:
- Back up important data before installing or removing drivers.
- Use the “recommended” driver unless you have a specific need for a newer or older version.
- After installing a GPU driver, reboot the system to load the new kernel modules.
- Check for kernel updates that might require re‑installation of the driver.
- Avoid mixing drivers from different sources (e.g., official Ubuntu packages and PPAs) unless you know the compatibility.
Frequently Asked Questions
What does the error “command not found” mean for ubuntu-drivers?
It indicates that the script is not in your $PATH or the package that provides it is missing. Install ubuntu-drivers-common or correct the PATH to resolve the issue.
Can I use ubuntu-drivers on a non‑Ubuntu distro?
Only Ubuntu and derivatives (e.g., Linux Mint, Pop!_OS) support the script. Other distributions have their own driver management tools.
Is it safe to install the latest NVIDIA driver with ubuntu-drivers?
Yes, if the driver is marked as “recommended.” It has passed Ubuntu’s testing for that release. If you need the absolute latest version, consider downloading from NVIDIA directly, but be prepared for potential instability.
Why does ubuntu-drivers autoinstall sometimes install the wrong driver?
Hardware detection can misinterpret a device, especially with virtual machines or legacy hardware. Verify the output of ubuntu-drivers devices and manually install the correct driver if needed.
How do I remove a driver installed by ubuntu-drivers?
Use sudo ubuntu-drivers remove driver-name or uninstall the package with sudo apt remove nvidia-driver-535. Reboot afterward.