TechBuzzPro

Install Old NVIDIA Drivers on Linux – Step‑by‑Step Guide

· 6 min read · Windows & PC

In this article
  1. What You’ll Need
  2. Step‑by‑Step
  3. Common Mistakes
  4. Tips
  5. Troubleshooting
  6. Frequently Asked Questions

Yes, you can install older NVIDIA drivers on a Linux system; you simply remove the current driver, select the legacy version that matches your GPU, and install it using the package manager or the official .run installer.

What You’ll Need

  • A Linux distribution that uses the apt package manager (e.g., Ubuntu, Linux Mint, Pop!_OS). Other distributions follow similar principles but command syntax may differ.
  • Administrative (sudo) privileges on the machine.
  • Internet access to download packages or the driver archive from NVIDIA’s website.
  • The exact model of your NVIDIA GPU (run lspci | grep -i nvidia to see it).
  • Optional: A USB stick or another bootable medium in case the graphical session fails and you need to recover.

Step‑by‑Step

  1. Identify the GPU and the driver series it belongs to. Run:
    lspci -k | grep -A 2 -i "VGA"
    Look for a line such as Subsystem: NVIDIA Corporation GP107 [GeForce GTX 1050]. Older GPUs (pre‑Pascal) require the legacy series (e.g., 340.xx, 390.xx). Newer GPUs can use the regular 470 or 515 series, but you may still prefer an older release for stability.
  2. Check which driver versions are available in the repository. Execute:
    apt search nvidia-driver
    The output will list packages like nvidia-driver-340, nvidia-driver-390, nvidia-driver-470, etc. Note the exact package name for the legacy version you need.
  3. Stop the graphical display manager. The command differs by distro:
    • Ubuntu with GDM: sudo systemctl stop gdm
    • Ubuntu with LightDM: sudo systemctl stop lightdm
    • Other: replace the service name with display-manager or use sudo service dm stop.
    This ensures the driver files are not in use while you replace them.
  4. Remove any existing NVIDIA driver packages. Run:
    sudo apt-get purge '^nvidia-.*'
    This removes the current driver, its configuration files, and any automatically installed dependencies.
  5. Blacklist the open‑source nouveau driver. Create or edit /etc/modprobe.d/blacklist-nouveau.conf with:
    sudo bash -c "echo -e 'blacklist nouveau\noptions nouveau modeset=0' > /etc/modprobe.d/blacklist-nouveau.conf"
    Then rebuild the initramfs so the blacklist takes effect:
    sudo update-initramfs -u
  6. Install the chosen legacy driver. If you prefer the repository package, run:
    sudo apt-get install nvidia-driver-340
    Replace 340 with the version you identified earlier. If the repository does not contain the exact legacy version, download the .run file from NVIDIA’s official driver archive.
    • Make the file executable: chmod +x NVIDIA-Linux-x86_64-340.108.run
    • Run the installer in console mode: sudo ./NVIDIA-Linux-x86_64-340.108.run --no-cc-version-check --no-nouveau-check
    • Answer the prompts – accept the license, let the installer create a new xorg.conf file, and decline the DKMS module if you do not need automatic kernel updates.
  7. Re‑enable the display manager and reboot. Start the service again:
    sudo systemctl start gdm   # or lightdm, sddm, etc.
    Then reboot to load the new kernel module:
    sudo reboot
  8. Verify the driver is active. After the system restarts, run:
    nvidia-smi
    The command should display the driver version you installed, the GPU model, and usage statistics. If it reports “NVIDIA-SMI has failed because it couldn’t communicate with the NVIDIA driver,” return to the troubleshooting section.

Common Mistakes

  • Attempting to install a legacy driver on a kernel that is newer than the driver supports. Legacy drivers often lag behind kernel releases; check the driver’s release notes for the maximum supported kernel version.
  • Leaving the nouveau driver loaded. If the blacklist file is missing or the initramfs is not rebuilt, both drivers may conflict, resulting in a black screen.
  • Using the graphical package manager while the display manager is still running. The installer may fail silently because the X server holds the GPU.
  • Skipping the purge step, which leaves old configuration files that can cause module mismatches.
  • Downloading the wrong architecture (e.g., 32‑bit driver on a 64‑bit system). Always verify the x86_64 label for modern PCs.

Tips

  • Keep a copy of the original xorg.conf (if one exists) before overwriting it. You can restore it with sudo cp /etc/X11/xorg.conf.backup /etc/X11/xorg.conf if the new driver causes problems.
  • If you frequently switch between driver versions, consider using update-alternatives to manage multiple nvidia-modprobe binaries.
  • For systems that use Secure Boot, you must either sign the kernel module yourself or disable Secure Boot in the BIOS; otherwise the driver will be blocked from loading.
  • When using the .run installer, add the --no-drm flag if you plan to use Wayland, as the legacy driver may not support the DRM kernel mode‑setting required by Wayland.
  • Document the exact driver version you installed in a text file (e.g., /etc/nvidia-driver-version) so future maintenance scripts can detect it.

Troubleshooting

If the system fails to boot into the graphical environment after installing an old driver, follow these steps in order of increasing impact.

  1. Restart and access a virtual console. Press Ctrl+Alt+F2 (or F3‑F6) at the black screen to get a text login prompt.
  2. Check the driver load status. Run lsmod | grep nvidia. If nothing appears, the module did not load.
  3. Inspect the Xorg log. View /var/log/Xorg.0.log for lines containing “(EE)” which indicate errors. Common messages include “Failed to load module nvidia” or “No screens found”.
  4. Re‑run the installer in safe mode. Boot into recovery mode (selected from the GRUB menu), choose “root” shell, and execute the installer with the --no-kernel-module option to only reinstall user‑space components.
  5. Temporarily revert to the open‑source driver. Remove the NVIDIA packages again (sudo apt-get purge '^nvidia-.*') and delete or rename /etc/X11/xorg.conf. Then reboot; the system should fall back to nouveau allowing you to recover the desktop.
  6. Update the kernel or switch to a supported one. If the kernel is newer than the driver supports, install an LTS kernel that matches the driver’s compatibility list (e.g., sudo apt-get install linux-image-5.15.0-50-generic).
  7. Disable Secure Boot. Enter the BIOS/UEFI setup, locate the Secure Boot option, and set it to “Disabled”. Save changes and reboot.
  8. Seek community help. Provide the output of nvidia-smi, uname -r, and relevant log excerpts on forums such as Ubuntu Forums or the NVIDIA Linux Developer forums.

Frequently Asked Questions

Can I install an old NVIDIA driver on a laptop that uses Optimus?

Yes, but you must also install bumblebee or prime-select to manage the hybrid graphics. The legacy driver works only on the discrete GPU; the integrated Intel GPU remains untouched.

Do I need to reinstall the driver after every kernel update?

If you used the repository package, DKMS will rebuild the module automatically. When using the .run installer, you must rerun the installer after each kernel change because the module is not automatically recompiled.

Is it safe to use the 340.xx driver on a modern desktop with a 1080 Ti?

No. The 340.xx series supports GPUs up to the GeForce GTX 500 series. Newer cards require at least the 390.xx or newer series.

What if my system uses Wayland instead of Xorg?

Legacy NVIDIA drivers have limited Wayland support. The safest approach is to switch the session to Xorg (select “Ubuntu on Xorg” at the login screen) or use a newer driver that explicitly supports Wayland.

Will disabling Secure Boot affect other drivers?

Disabling Secure Boot only affects drivers that are not signed with a trusted key. Most open‑source drivers are unaffected; however, any third‑party kernel modules will also load without signature verification.

Can I keep two different NVIDIA driver versions installed simultaneously?

The package manager prevents co‑installation of conflicting driver packages. You can keep the .run installer of a previous version as a backup, but only one version can be active at a time.