Thursday, March 12, 2026

uninstalling ollama

https://github.com/ollama/ollama/issues/986

ran all the lines suggested there, got some 15 GB freed.

Copy-pasting from the above,

Here's a general guideline on how to uninstall it:

Delete the Ollama binary:
Use the rm command to remove the Ollama binary. For example:

sudo rm /usr/local/bin/ollama

If the script created a systemd service, disable and remove it:
If the script created a systemd service for Ollama, you should disable and remove it using the following commands:

sudo systemctl stop ollama
sudo systemctl disable ollama
sudo rm /etc/systemd/system/ollama.service
sudo systemctl daemon-reload

Remove any created user and group (if applicable):
The script might have created a user and group named "ollama." You can remove them using the following commands:

sudo userdel ollama
sudo groupdel ollama

-----------------------

More lines from other people, esp if location of ollama and downloaded models are different - 

sudo rm -v /usr/local/bin/ollama
sudo rm -rv /usr/local/lib/ollama

sudo systemctl stop ollama
sudo systemctl disable ollama
sudo rm -v /etc/systemd/system/ollama.service
sudo systemctl daemon-reload

sudo userdel ollama
sudo groupdel ollama

sudo rm -rv /usr/share/ollama
# for downloaded models

rm -rv ~/.ollama

sudo rm -rv /usr/lib/ollama/
sudo rm -rv /usr/local/lib/ollama


No comments:

Post a Comment