[GH-ISSUE #8572] Ollama cannot start because it try to create an existing directory #52048

Closed
opened 2026-04-28 21:44:33 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @brianhuster on GitHub (Jan 25, 2025).
Original GitHub issue: https://github.com/ollama/ollama/issues/8572

What is the issue?

Since my main partition doesn't have enough memory, I change OLLAMA_MODELS to /media/brianhuster/E/ollama/models. I have created that directory, and mv /usr/share/ollama/.ollama/models /media/brianhuster/E/ollama/models. However, after that I cannot restart Ollama because, according to sudo journalctl -u ollama.service -n 50, the error come from

Error: mkdir /media/brianhuster/E: permission denied

The problem is that /media/brianhuster/E already exists, so why the does it try to recreate it? Not to say that I have even change the owner of /media/brianhuster/E to ollama:ollama, that still doesn't help.

drwxrwxr-x 4 ollama ollama 4096 Thg 1  25 11:00 /media/brianhuster/E/

OS

Linux

GPU

Intel

CPU

Intel

Ollama version

Warning: could not connect to a running Ollama instance Warning: client version is 0.5.7

Originally created by @brianhuster on GitHub (Jan 25, 2025). Original GitHub issue: https://github.com/ollama/ollama/issues/8572 ### What is the issue? Since my main partition doesn't have enough memory, I change OLLAMA_MODELS to /media/brianhuster/E/ollama/models. I have created that directory, and `mv /usr/share/ollama/.ollama/models /media/brianhuster/E/ollama/models`. However, after that I cannot restart Ollama because, according to `sudo journalctl -u ollama.service -n 50`, the error come from ``` Error: mkdir /media/brianhuster/E: permission denied ``` The problem is that /media/brianhuster/E already exists, so why the does it try to recreate it? Not to say that I have even change the owner of `/media/brianhuster/E` to `ollama:ollama`, that still doesn't help. ``` drwxrwxr-x 4 ollama ollama 4096 Thg 1 25 11:00 /media/brianhuster/E/ ``` ### OS Linux ### GPU Intel ### CPU Intel ### Ollama version Warning: could not connect to a running Ollama instance Warning: client version is 0.5.7
GiteaMirror added the bug label 2026-04-28 21:44:33 -05:00
Author
Owner

@rick-github commented on GitHub (Jan 25, 2025):

sudo chmod o+x  /media/brianhuster
<!-- gh-comment-id:2613843761 --> @rick-github commented on GitHub (Jan 25, 2025): ``` sudo chmod o+x /media/brianhuster ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#52048