Skip to content

Docs: Add Linux manual instructions that can run without root / sudo #7421

Description

@gabe-l-hart

Description

In the Linux manual install instructions, the commands are shown requiring sudo access. This is usually fine with personal machines, but often isn't for shared or managed machines. The request here is to add instructions on how to install without root access.

Proposal

I'm happy to contribute the README PR. Here are my suggested changes:


Manual install

Download and extract the package:

curl -L https://ollama.com/download/ollama-linux-amd64.tgz -o ollama-linux-amd64.tgz
sudo tar -C /usr -xzf ollama-linux-amd64.tgz

Non-root install

For those installing without root/sudo access, the install can also be done in user space with the appropriate additions to PATH and LD_LIBRARY_PATH:

curl -L https://ollama.com/download/ollama-linux-amd64.tgz -o ollama-linux-amd64.tgz
# Substitute any place you have write access for ~/.local
mkdir -p ~/.local
tar -C ~/.local -xzf ollama-linux-amd64.tgz
# Place this in your ~/.bashrc to persist
export PATH=$HOME/.local/bin:$PATH
export LD_LIBRARY_PATH=$HOME/.local/lib/ollama:$LD_LIBRARY_PATH

Start Ollama:

ollama serve

In another terminal, verify that Ollama is running:

ollama -v

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions