Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →Set the supported OLLAMA_MODELS environment variable to an absolute directory, then restart the Ollama systemd service. On a standard Linux installation, the service normally uses /usr/share/ollama/.ollama/models; changing the variable does not move models that are already there, so you must copy the existing blobs and manifests directories or download the models again.
Need a server to try this on? Antihost offers Linux VPS plans with NVMe storage, full root access and a 14-day free trial.
What changes when you set OLLAMA_MODELS?
OLLAMA_MODELS tells Ollama where to store and find model data. The path must be absolute, such as /mnt/large-drive/ollama-models. It is the supported setting identified in Ollama’s official FAQ for changing the model directory.
As an Amazon Associate I earn from qualifying purchases.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
On Linux installed with Ollama’s standard installer and managed by systemd, the documented default is /usr/share/ollama/.ollama/models. A user who starts ollama serve manually can instead see a model directory under that user’s home directory, because a manually launched process inherits the launching user’s environment. Those are different service contexts and can point at different model stores.
Changing the variable changes the directory Ollama checks from that point forward. It does not copy existing data. Until you migrate the existing files or pull each model again, ollama list can appear empty after the restart.
#1 Best Overall
- Capacity Display Variance: 250GB external ssd often appears as around 232GB on Windows. MacOS can show full 250 GB capacity. This is binary calculation difference and doesn’t affect SSD hard drive actual physical storage
- 1050 MB/s Speed: Instantly access to your files with blazing-fast 10Gbps external SSD read up to 1050MB/s and write up to 1000MB/s. LED Light indicates USB SSD instant activity
- Data Security: Solid state drives S.M.A.R.T. health diagnostics and adaptive TRIM optimizing data block management ensures consistent write speeds and extends the longevity of the portable SSD
- USB-C & USB-A Cable: Both cables featuring rapid USB 3.2 Gen2, this USB SSD effortlessly bridges devices, enabling seamless cross-platform file transfers and backup between computers, smartphones, tablets and iPhone
- Always Fast: No slowdowns for large file transfers. With SLC caching (25% of current available capacity allocated as high-speed cache), this external SSD delivers steady 10Gbps for transfers within the cache capacity
Before you move anything
- Confirm that the destination filesystem is mounted at the path you intend to use. A mounted external or secondary drive supplies capacity, but it still has to be available whenever the Ollama service starts.
- Use an absolute destination path. Relative paths do not provide a reliable system-service configuration.
- Check which process you actually use. The instructions below apply to a native Linux installation managed by systemd. Docker, distribution packages, and custom launchers may require setting the variable in their own container or service environment.
- Plan for the service account. The standard installer runs the service as the
ollamauser, which needs read and write access to the destination.
Set the model path permanently with systemd
For a systemd installation, Ollama’s FAQ says environment variables should be set with systemctl. A drop-in override is persistent across reboots and package restarts.
1. Create a systemd override
- Open the service override editor:
sudo systemctl edit ollama.service. - In the editor, add this section exactly, replacing the path with the mounted directory you chose:
[Service] Environment="OLLAMA_MODELS=/mnt/large-drive/ollama-models" - Save the file and exit the editor. The override is stored separately from the vendor unit, so a normal package update does not require editing the original service file again.
2. Create the destination and assign ownership
Create the directory before restarting Ollama, then grant the service account ownership:
sudo mkdir -p /mnt/large-drive/ollama-models
sudo chown -R ollama:ollama /mnt/large-drive/ollama-models
The ownership command matters even when the directory is on another internal disk or an external SSD. If the service cannot read and write the directory, pulls and model startup can fail with permission errors.
3. Reload systemd and restart Ollama
sudo systemctl daemon-reload
sudo systemctl restart ollama
daemon-reload makes systemd read the new drop-in; the restart launches Ollama with the updated environment. Do not leave a second manually started ollama serve process running while testing. Two processes can listen in different contexts and make a correct service setting look ineffective.
Move models that are already downloaded
The new path starts empty unless you migrate the existing store. Ollama model data is organized beneath the model directory’s blobs and manifests directories. Preserve both directories and their contents.
Option A: copy first, then verify
Copying lets you keep the original until the new location works. Stop the service so files are not changing during the copy:
Do these 3 things before closing this tab:
1Repair Windows errors before they cause bigger problems2Scan for outdated or missing drivers - takes under a minute3Clear out junk files and repair common Windows errorsRank #2
- Blazing fast NVMe technology with speeds of up to 1050MB/s and write speeds of up to 1000MB/s | Based on read speed unless otherwise stated. As used for transfer rate, 1 MB/s = one million bytes per second. Based on internal testing; performance may vary depending upon host device, usage conditions, drive capacity, and other factors..date transfer rate:1050.0 megabits_per_second.Compatibility : Windows 10+ operating systems, macOS 11+.
- Password enabled 256-bit AES hardware encryption
- Shock and vibration resistant. Drop resistant up to 6.5ft (1.98m)
- Cross Compatible USB 3.2 Gen-2 and USB-C (USB-A for older systems)
- 5-year manufacturer's limited warranty
sudo systemctl stop ollama
sudo mkdir -p /mnt/large-drive/ollama-models
sudo cp -a /usr/share/ollama/.ollama/models/blobs /mnt/large-drive/ollama-models/
sudo cp -a /usr/share/ollama/.ollama/models/manifests /mnt/large-drive/ollama-models/
sudo chown -R ollama:ollama /mnt/large-drive/ollama-models
The source path above is the standard systemd location. If your installation or previous configuration used another directory, substitute that directory while keeping the blobs and manifests layout intact. The -a option preserves file attributes during the copy; the final ownership command ensures the service account can use the result.
Option B: move the directories
If you have a verified backup or need to reclaim the old disk immediately, move the two directories instead of copying them. Stop Ollama first, create the destination, move blobs and manifests into it, and run the ownership command again. A move across filesystems can take as long as a copy, so do not interrupt it or remove the source until the operation completes.
Option C: pull models again
For a small model collection, you can leave the old files in place and pull each required model after the service is configured. This is simpler but uses bandwidth and repeats the download. Existing models will not appear merely because the variable changed.
Verify that the service uses the new directory
- Check the service state:
sudo systemctl status ollama. Confirm that the service is running without an immediate exit or permission failure. - List models through the service:
ollama list. Migrated models should appear after the restart. - If the destination is empty, pull a small known model to test writing:
ollama pull <model-name>. Replace the placeholder with a model name you intend to use. - Inspect service logs if the list is empty or the pull fails:
journalctl -u ollama. Look for path, permission, mount, or startup errors. - Confirm that the destination contains the expected
blobsandmanifestsdirectories and that they are owned byollama:ollama.
Run client commands against the same server that you configured. A shell command can connect to a manually launched process while systemd is running a separate process, so checking only the client output can be misleading.
PC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11Outdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchWhy Ollama still uses ~/.ollama/models
A manually started server is still running
The most common explanation is a second, unmanaged ollama serve. A manually launched server inherits the login user’s environment and may use a home-directory store, while the systemd service uses the drop-in environment. Stop the manual process, keep one server process, then check sudo systemctl status ollama and journalctl -u ollama again.
The override was edited in the wrong place
Use sudo systemctl edit ollama.service rather than editing a vendor unit under system directories. After saving the override, run sudo systemctl daemon-reload and restart the service. Without the reload and restart, the running process continues with its old environment.
Rank #3
- Capacity Reminder: Display capacity of 2TB SSD often appears as around 1863GB on Windows. MacOS typically shows full 2TB. This display capacity reduction of 7% to 10% from SSD actual capacity is from algorithms differences in which 1GB is interpreted as 1024MB on Windows and 1000MB on SSDs
- 1000 MB/s Speed: Instantly access to your files with blazing-fast 10Gbps external SSD read up to 1000MB/s and write up to 1000MB/s. LED Light indicates USB SSD instant activity
- Data Security: Master solid state drives health with S.M.A.R.T. monitoring. TRIM technology ensures consistent write speeds and extends the lifespan of the portable SSD
- USB-C & USB-A Cable: Both USB-C and USB-A cables featuring rapid USB 3.2 Gen2, this USB SSD effortlessly bridges devices, enabling seamless cross-platform file transfers between computers, smartphones, tablets and Phones
- Always Fast: No slowdowns during large file transfers. When transferring files smaller than 500GB, this external ssd remains steady 10Gbps with SLC caching (25%of the current available capacity is allocated for high speed cache)
The service and your shell are different users
Your interactive shell may show a home-directory path because it belongs to your login account. The standard systemd service runs as ollama, so its model path and permissions are independent of files in your home directory. Configure the context that actually serves requests.
You changed the path but did not migrate data
A new directory has no knowledge of files left in the old directory. Copy or move both blobs and manifests, or pull the models again, then repeat ollama list.
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Permissions and filesystem problems
Permission denied during a pull
Make sure the destination exists and is writable by the service account:
sudo mkdir -p /mnt/large-drive/ollama-models
sudo chown -R ollama:ollama /mnt/large-drive/ollama-models
Also check parent directories. The ollama user needs permission to traverse the path, not only to write the final directory. A filesystem mounted with restrictive ownership or access options can still block the service after chown; the journal normally identifies the failing path.
The drive is not mounted after reboot
If the mount is unavailable when systemd starts Ollama, the configured directory may resolve to an empty directory on the root filesystem, or the service may fail to start. Configure the drive to mount reliably before relying on the service, and verify the mount is present before restarting Ollama. Do not delete the old model store until you have confirmed the intended filesystem is mounted and populated.
The destination has insufficient capacity
Moving models to a larger drive addresses capacity only when Ollama can consistently access that drive. Keep the mount path stable, leave room for future pulls, and monitor the filesystem separately from Ollama. An external SSD can provide space, but it does not configure OLLAMA_MODELS, preserve service ownership, or guarantee availability at boot.
Free tools Windows power users keep installed
One-click scans. No signup required.
Rank #4
- External SSD with USB4 Connection: Leverage the incredibly high bandwidth of USB4 to move large files for tasks like video and photo editing in seconds.
- Lightning-Fast Speeds: Delivers data speeds of up to 4,000MB/sec sequential read and up to 3,500MB/sec sequential write.
- Compatible with USB Type-C: Connect via USB Type-C, Thunderbolt 4 and higher for wide compatibility*. *Performance varies by capacity. Maximum performance requires USB4 or higher connection.
- Compact Form Factor: Small form factor allows you to take the EX400U with you for high-performance storage on the go.
- Simple Plug-and-Play Setup: Easy to use right out of the box with a single connection for power and data on PC or Mac.
Systemd override versus a one-shell export
You can set the variable temporarily in a shell, but that does not configure the system service. The choice depends on which process should use the path.
| Approach | Persistence | Service identity | When it is useful | Migration consequence |
|---|---|---|---|---|
systemctl edit ollama.service |
Persists for the systemd service across restarts and reboots | System ollama account |
Native Linux installation operated as a background service | Copy or move the existing store for that service, or re-pull models |
One-shell export OLLAMA_MODELS=... |
Only the current shell and processes launched from it | Your login user | Testing or running a user-managed ollama serve |
User-run server sees the user-owned model directory; systemd does not automatically use it |
If your goal is a dependable server that starts with Linux, use the systemd override. Use a shell export only when you intentionally run Ollama under your login account and understand that it is a separate process context.
Installation types outside the standard systemd setup
The documented procedure targets a native Linux installation managed by systemd. Docker containers, distribution packages, and custom launchers may define their own environment and storage settings. Set OLLAMA_MODELS in the container definition, package service, or launcher that starts your Ollama process, then apply that environment’s restart procedure. Do not assume a systemd drop-in affects a container or a separately packaged service.
The same practical requirements still apply: use an absolute directory, ensure the process can read and write it, make the storage available when the process starts, and migrate the old blobs and manifests data or re-pull the models.
A safe end-to-end checklist
- Choose a mounted filesystem with enough capacity and a stable path.
- Stop any manually launched
ollama serveprocess so only the intended server remains. - Create the destination directory.
- Copy or move the existing
blobsandmanifestsdirectories, or decide to re-pull models. - Set ownership to
ollama:ollamafor the standard systemd installation. - Run
sudo systemctl edit ollama.serviceand addEnvironment="OLLAMA_MODELS=/absolute/path"beneath[Service]. - Run
sudo systemctl daemon-reload, thensudo systemctl restart ollama. - Check
sudo systemctl status ollama, runollama list, and inspectjournalctl -u ollamaif anything is missing. - Only remove the old model directory after the new location has served a model successfully.
Bottom line
For a standard Linux systemd installation, the reliable method is a systemd drop-in containing OLLAMA_MODELS, followed by a daemon reload and service restart. The destination must be writable by the ollama account, and existing model data must be copied, moved, or downloaded again. If Ollama appears to ignore the setting, eliminate any second manually started server before changing the configuration further.
Quick Recap
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.




