Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

Ollama’s documented Linux install script is the simplest option for Ubuntu: install zstd if needed, then run curl -fsSL https://ollama.com/install.sh | sh. You can also extract the Linux archive manually or run Ollama in Docker. The official Linux instructions do not make a release-specific compatibility statement for Ubuntu 26.04, so treat that version as unconfirmed rather than guaranteed.

Before you install

These instructions cover Ubuntu 24.04 and 26.04, but the distinction matters: Ollama’s Linux documentation describes Linux installation without naming either Ubuntu release. It therefore does not establish specific support for Ubuntu 26.04. A community issue reports an installation failure on a clean Ubuntu 26.04 system without the zstd command-line utility; that is a reported case, not an official compatibility ruling. See the community issue tracker.

On a fresh Ubuntu installation, check that zstd is available before using the script or a compressed archive. The current installer prefers a .tar.zst archive when available and exits with an instruction to install zstd if it cannot extract that format. Its source gives this Debian/Ubuntu command:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
sudo apt-get install zstd

The installer can use a .tgz archive for older versions, but do not assume that fallback will apply to the current release. Review the Ollama install script.

Option 1: Install with the official Linux script

Ollama documents the install script as its standard Linux installation route. It detects the system architecture, supports x86_64 and ARM64, selects the corresponding archive, and installs Ollama in a directory associated with the system binary path. The Linux documentation says the installer configures a systemd service when possible. See Ollama’s Linux installation guide.

  1. Install zstd if it is missing: run sudo apt-get install zstd.
  2. Run the installer:
    curl -fsSL https://ollama.com/install.sh | sh
  3. Check the CLI: run ollama -v in a terminal.

To install a particular release, set OLLAMA_VERSION for the installer. Consult the current release list rather than relying on an old version number. Rerunning the installer is also the documented update method. See the Linux documentation for version selection and updates.

Start Ollama and verify it is available

If you used the manual archive method below, start the service with ollama serve. The Linux guide says the script configures a systemd service when possible; if installation did not start the service automatically, run the command below in a terminal and leave it open while using Ollama.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
ollama serve

Open a second terminal and check the installed command:

ollama -v

A version response confirms that the CLI is installed and callable. If the shell cannot find ollama, check that installation completed and that its install directory is on your system’s command path.

Option 2: Install from a Linux tarball

The manual method extracts an archive under /usr. The official Linux guide shows this amd64 command; it also lists separate ARM64 and AMD ROCm archives for the appropriate systems. The compressed archive requires zstd support for extraction.

curl -fsSL https://ollama.com/download/ollama-linux-amd64.tar.zst 
  | sudo tar x -C /usr
  1. Choose the archive that matches your architecture and, where relevant, the AMD ROCm library set.
  2. Run the extraction command for the applicable archive. For a fresh Ubuntu system, make sure zstd is installed first.
  3. Start Ollama with ollama serve.
  4. In another terminal, verify the CLI with ollama -v.

Unlike the script route, the manual example is an extraction command rather than an installer flow. Use it when you want to manage archive installation yourself. The Linux guide lists the available archives.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Option 3: Run Ollama in Docker

Docker is a fit if you want Ollama managed as a container. The official CPU-only command publishes port 11434 and mounts a named volume at /root/.ollama, so Ollama data persists beyond the container’s lifetime.

docker run -d -v ollama:/root/.ollama -p 11434:11434 --name ollama ollama/ollama

GPU use needs additional host configuration and a vendor-specific container setup:

  • NVIDIA: Install the NVIDIA Container Toolkit, configure Docker’s runtime, and pass --gpus=all to the container command.
  • AMD: Use the ollama/ollama:rocm image tag and pass the /dev/kfd and /dev/dri devices to the container.

Follow the Docker guide for the exact setup details for your GPU and host. See Ollama’s Docker instructions.

Which installation method should you choose?

Method Best suited to Key detail
Install script Most Linux users who want Ollama installed on the host Detects supported architecture and configures a systemd service when possible; current archive handling can require zstd.
Manual tarball Users who want to extract and manage the archive themselves Extracts under /usr; start with ollama serve and verify with ollama -v.
Docker Users who prefer container management or need the documented GPU container setup CPU command retains data in a named volume; NVIDIA and AMD require different host configuration.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.