GuideGlitchesField notes for broken tech GuideGlitches
Ubuntu 22.0415-Minute FixTerminal Required26 Oct 2026 · Satyam · 5 min

GPU not detected by Ollama: Fix on Ubuntu 22.04

Steps

  1. 1

    Open the terminal by pressing Ctrl + Alt + T.

    The terminal window should appear on your screen. If it does not, try searching for 'Terminal' in the application menu.

  2. 2

    Check the current GPU drivers with the command.

    You should see a list of installed drivers. If no drivers are listed, you need to install the appropriate ones for your GPU.

    Terminal
    lspci | grep -i vga
  3. 3

    sudo apt update

    Update your package list to ensure you have the latest drivers.

    The terminal should show progress as it updates the package list. If it fails, check your internet connection.

    Terminal
    sudo apt update
  4. 4

    sudo ubuntu-drivers autoinstall

    Install the recommended GPU drivers for your system.

    The terminal should confirm the installation of the drivers. If it fails, ensure you have the correct drivers for your GPU model.

    Terminal
    sudo ubuntu-drivers autoinstall
  5. 5

    sudo reboot

    Reboot your system to apply the changes.

    Your system should restart. After rebooting, check if the GPU is now detected by Ollama.

    Terminal
    sudo reboot
  6. 6

    lspci | grep -i vga

    Verify the GPU detection after reboot.

    Run the command again to check if the GPU is now listed. If it is still not detected, further troubleshooting may be required.

    Terminal
    lspci | grep -i vga
GPU not detected by Ollama: Fix on Ubuntu 22.04
Photo by Anthony Roberts on Unsplash

A related guide is Step-by-Step AI on a Budget Laptop Setup Guide.

Questions

What should I do if my GPU is still not detected?

If your GPU is still not detected, check for hardware issues or compatibility problems. You may also need to reinstall the drivers or check for system updates.

How can I check if my GPU drivers are installed correctly?

You can check if your GPU drivers are installed correctly by running the command 'lspci | grep -i vga' in the terminal. This will list the detected GPU and its driver.

Can I manually install GPU drivers on Ubuntu?

Yes, you can manually install GPU drivers on Ubuntu using the terminal. Use the command 'sudo ubuntu-drivers autoinstall' to install recommended drivers.