Background.
The concept is simple. I want to search for the string OLLAMA_MODEL in the file `C:\Users\USERNAME\AppData\Local\Ollama` but the OS says it cannot find the file. The file appears to be hidden. I can use the File Explorer to open the directory. I'm the only user on this home machine so I'm also the admin.
I also tried copying the file to another directory but the error I get is "Cannot find file". So how do I search this file if I'm the admin user, to find the string I want?
My .bat file looks like this currently:
This also gives me an error "File not found".
- I have a Desktop shortcut to open a cmd.exe window to the Ollama directory program. This shortcut also runs a .bat file to set up some paths and other environment variables.
The concept is simple. I want to search for the string OLLAMA_MODEL in the file `C:\Users\USERNAME\AppData\Local\Ollama` but the OS says it cannot find the file. The file appears to be hidden. I can use the File Explorer to open the directory. I'm the only user on this home machine so I'm also the admin.
I also tried copying the file to another directory but the error I get is "Cannot find file". So how do I search this file if I'm the admin user, to find the string I want?
My .bat file looks like this currently:
Code:
@echo off
rem Updated: 3/30/25
rem This file seems to be hidden: C:\Users\USERNAME\.ollama\models\app.log
set tfile=C:\Users\USERNAME\.ollama\models\app.log
set tfile2=.\app.log
copy %tfile% %tfile2%
if %ERRORLEVEL% NEQ 0 (
echo ERROR: File could not be copied!
goto myexit
)
findstr /i /n OLLAMA_MODEL %tfile2%
:myexit
This also gives me an error "File not found".
Code:
@echo off
rem Updated: 3/30/25
rem Ollama is in c:\users\USERNAME\AppData\Local\Programs\Ollama\
rem This file seems to be hidden: C:\Users\USERNAME\.ollama\models\app.log
set tfile=C:\Users\USERNAME\.ollama\models\app.log
dir /s /b /a:H %tfile% | findstr /i /c:"OLLAMA_MODEL: %tfile%
:myexit
Last edited:
My Computer
System One
-
- OS
- Windows 11
- Computer type
- PC/Desktop
- Manufacturer/Model
- HP Omen GT13-1xxx
- CPU
- AMD Ryzen 5 5600G with Radeon Graphics 6 cores
- Memory
- 16GB
- Graphics Card(s)
- Nvideo GeForce RTX 3060
- Hard Drives
- C: SSD, with other hard drives from old PCs.