[GH-ISSUE #4528] OLLAMA_MODELS no longer works #28599

Closed
opened 2026-04-22 07:00:26 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @asmrtfm on GitHub (May 20, 2024).
Original GitHub issue: https://github.com/ollama/ollama/issues/4528

Originally assigned to: @dhiltgen on GitHub.

setting the OLLAMA_MODELS environment variable (was) no longer working.

[ edit: A reboot resolved this, so closed.

  • additional details:
    models were in ~/.ollama (ownership: 1000:1000);
    environment variable was accidentally commented out in ~/.bashrc before a reboot - so, unsurprisingly, no dice;
    uncommented line in .bashrc;
    re-login'd;
    models still not detected;
    killed ollama;
    . ~/.bashrc'd for good measure;
    re-ran ollama serve & ollama list;
    no dice;
    killed ollama;

then:

I tried making /usr/share/ollama/.ollama a symlink to ~/.ollama;

and then:
chown -R ollama ~/.ollama/models/... ;
ollama serve & ollama list;
same amount of dice;

also noticed:
at one (non-canonical) point, ollama failed to start from cmd line and yielded an error msg that, to me, seemed to suggest it tries to (re)generate the default directory upon launch - with something equivalent to mkdir instead of something equivalent to mkdir -p;

...eventually deleted symlink and rebooted;
seems to be working;
closed this.

OS

Linux

GPU

Nvidia

CPU

Intel

Originally created by @asmrtfm on GitHub (May 20, 2024). Original GitHub issue: https://github.com/ollama/ollama/issues/4528 Originally assigned to: @dhiltgen on GitHub. > setting the OLLAMA_MODELS environment variable (was) no longer working. [ edit: A reboot resolved this, so closed. * additional details: models were in ~/.ollama (ownership: 1000:1000); environment variable was accidentally commented out in ~/.bashrc before a reboot - so, unsurprisingly, no dice; uncommented line in .bashrc; re-login'd; models still not detected; killed ollama; `. ~/.bashrc`'d for good measure; re-ran `ollama serve & ollama list;` no dice; killed ollama; then: > I tried making /usr/share/ollama/.ollama a symlink to ~/.ollama; and then: `chown -R ollama ~/.ollama/models/...` ; `ollama serve & ollama list;` same amount of dice; also noticed: at one (non-canonical) point, ollama failed to start from cmd line and yielded an error msg that, to me, seemed to suggest it tries to (re)generate the default directory upon launch - with something equivalent to `mkdir` instead of something equivalent to `mkdir -p`; ...eventually deleted symlink and rebooted; seems to be working; closed this. ### OS Linux ### GPU Nvidia ### CPU Intel
GiteaMirror added the bug label 2026-04-22 07:00:26 -05:00
Author
Owner

@dhiltgen commented on GitHub (May 21, 2024):

Can you share the server log? This sounds like it might be a permission problem. Make sure the OLLAMA_MODELS dir is writable by the user or group ollama is running as.

<!-- gh-comment-id:2123250720 --> @dhiltgen commented on GitHub (May 21, 2024): Can you share the server log? This sounds like it might be a permission problem. Make sure the OLLAMA_MODELS dir is writable by the user or group ollama is running as.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#28599