A lightweight terminal monitor for Ubuntu/Linux designed for running local LLMs with Ollama, providing real-time metrics for models, CPU, RAM, swap, NVIDIA GPUs, VRAM, temperature, power usage, and LLM performance benchmarks.
Current version: v2.2.5
The project was created to make it easier to see what is actually happening while local models are running, with particular attention to multi-GPU systems, mobile workstations, and NVIDIA eGPU setups.
- Main Features
- Requirements
- Installation
- Quick Start
- Monitor Panels
- Ollama Metrics
- NVIDIA GPU Metrics
- System Metrics
- LLM Benchmark
- Real Prompt Metrics with ollama-monitored-run
- Automatic Benchmarking
- Active Model and STALE State
- Cold and Warm Runs
- Recommended GPU Comparison Protocol
- Remote Ollama
- Shared State File
- Running Without Installation
- Troubleshooting
- Known Limitations
- Full Changelog
- Recommended Workflow
- Possible Future Improvements
- License
- Version
The monitor displays the following information in real time:
- currently loaded Ollama models;
- model size;
- amount of the model resident in VRAM;
- CPU/GPU residency ratio;
- context length;
- remaining time before model unload;
- quantization and parameter size when available;
- NVIDIA GPU utilization;
- memory-controller utilization;
- VRAM used and total VRAM;
- GPU temperature;
- power draw and power limit;
- P-State;
- GPU and memory clocks;
- PCI bus ID;
- PCIe generation and link width when available;
- NVIDIA driver version;
- CUDA processes;
- VRAM allocated by Ollama processes;
- CPU utilization;
- CPU temperature;
- load average;
- RAM usage;
- swap usage;
- root filesystem usage;
- Ollama processes with CPU/RAM/RSS metrics;
- LLM benchmark metrics;
- TTFT;
- prompt processing tok/s;
- generation tok/s;
- model load duration;
- total request duration;
- optional integration with
blackwell-egpu status.
No third-party Python packages are required.
- Linux / Ubuntu
- Python 3
- Ollama
The following command must work:
nvidia-smiIf the following command is available:
blackwell-egpu statusthe monitor automatically adds a dedicated eGPU panel.
Download and extract the current release package:
unzip ollama-monitor-v2.2.5-ubuntu26.zip
cd ollama-monitor-v2.2.5Install:
chmod +x install.sh
./install.shThe installer copies:
~/.local/bin/ollama-monitor
~/.local/bin/ollama-monitored-run
If ~/.local/bin is not in your PATH:
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
source ~/.bashrcVerify the installation:
command -v ollama-monitor
command -v ollama-monitored-runExpected output:
/home/USER/.local/bin/ollama-monitor
/home/USER/.local/bin/ollama-monitored-run
The current installer also verifies that both commands can actually start:
ollama-monitor --help
ollama-monitored-run --helpStart the monitor:
ollama-monitorRefresh every 2 seconds:
ollama-monitor -i 2Quit with:
q
or:
Ctrl-C
The interface is approximately organized as follows:
OLLAMA LOCAL LLM MONITOR v2.2.5
── OLLAMA ───────────────────────────────────────────────
...
── LLM BENCHMARK ────────────────────────────────────────
...
── NVIDIA GPU ───────────────────────────────────────────
...
── BLACKWELL eGPU ───────────────────────────────────────
...
── SYSTEM ───────────────────────────────────────────────
...
── OLLAMA PROCESSES ─────────────────────────────────────
...
The monitor queries:
GET /api/ps
and displays currently resident models.
Example:
MODEL SIZE CPU/GPU VRAM CTX EXPIRES
qwen3.8:27B 18.0 GiB 25/75% 13.5 GiB 4096 3m 42s
params=27B quant=Q4_K_M
Ollama provides:
size
size_vram
The monitor calculates:
GPU % = size_vram / size * 100
CPU % = 100 - GPU %
This value describes how much of the model is resident on the GPU compared with the model's total size.
It does not represent the GPU's instantaneous computational utilization.
Each NVIDIA GPU visible through nvidia-smi is displayed separately.
Available metrics include:
GPU utilization
Memory-controller utilization
VRAM used / total
Temperature
Power draw / power limit
P-State
SM clock
Memory clock
PCI Bus ID
PCIe generation
PCIe width
Driver version
CUDA processes
Per-process VRAM
Example:
GPU 1 NVIDIA GeForce RTX 5060 Ti
GPU ███████████████░░░ 78%
VRAM ████████████████░░ 13.5 GiB / 16.0 GiB
Temp 63°C
Power 118W / 180W
PCIe Gen 3 x4
OLLAMA pid=4318 VRAM=13820 MiB
This is particularly useful on multi-GPU and eGPU systems because it shows not only whether a GPU is visible to Linux, but also whether Ollama has actually allocated VRAM on that device.
When blackwell-egpu status is available, the monitor can display additional eGPU-specific information such as:
mode
wait
eGPU enclosure
NVIDIA GPU name
PCIe link speed
PCIe RX / TX
iGPU state
Example:
── BLACKWELL eGPU ────────────────────────────────────────
NVIDIA GeForce RTX 5060 Ti (AORUS RTX506T AI BOX)
Same device as NVIDIA GPU 0 — GPU/VRAM/Temp/Power shown above
Mode 3 Wait 0 Link 16GT/s (Gen4)
PCIe RX/TX 12 / 1019
iGPU: Integrated GPU
If blackwell-egpu identifies the same physical GPU already displayed in the NVIDIA GPU panel, the following duplicate values are omitted from the BLACKWELL panel:
GPU utilization
VRAM usage
Temperature
Power
The BLACKWELL-specific data remains visible.
Deduplication is deliberately conservative. Duplicate metrics are hidden only when the helper GPU can be matched unambiguously to exactly one NVIDIA GPU.
If multiple identical GPUs are present and the match is uncertain, the complete BLACKWELL panel remains visible.
The SYSTEM panel displays:
CPU utilization
CPU temperature
Load average
RAM used / total
Swap used / total
Root filesystem usage
Example:
CPU 36.2%
Temp 62°C
Load 4.21 3.55 2.80
RAM 18.5 GiB / 31.8 GiB
SWAP 1.1 GiB / 8.0 GiB
ROOT 47%
Starting with v2, the monitor includes an integrated Ollama benchmark.
The main metrics are:
TTFT
Prompt eval tok/s
Generation tok/s
Prompt tokens
Generated tokens
Prompt duration
Model load duration
Total Ollama duration
Done reason
Example:
── LLM BENCHMARK ─────────────────────────────────────────
qwen3.8:27B state=done [monitor benchmark]
TTFT 2.84 s
Prompt eval 114.36 tok/s
Generation 18.72 tok/s
Generated 128 tok
Prompt tokens 31
Prompt duration 271 ms
Model load 73 ms
Total Ollama 9.77 s
Done reason length
Ollama returns:
prompt_eval_count
prompt_eval_duration
eval_count
eval_duration
The monitor calculates:
Prompt tok/s =
prompt_eval_count / prompt_eval_duration_seconds
and:
Generation tok/s =
eval_count / eval_duration_seconds
The final token-rate values therefore come from Ollama's actual runtime counters rather than from counting streamed HTTP chunks.
TTFT means:
Time To First Token
It is measured client-side from the moment the request is sent until the first non-empty output is received.
Starting with v2.1, the monitor considers both:
thinking
and:
response
This is important for reasoning models, which may start producing thinking content before the final visible response.
When a model is loaded, press:
b
The monitor benchmarks the model currently considered active.
You can also start a benchmark directly:
ollama-monitor --benchmark qwen3.8:27BWith 256 generated tokens:
ollama-monitor \
--benchmark qwen3.8:27B \
--benchmark-tokens 256With a custom benchmark prompt:
ollama-monitor \
--benchmark qwen3.8:27B \
--benchmark-tokens 256 \
--benchmark-prompt "Explain how transformer inference works."An important limitation of GET /api/ps is that it shows which models are loaded, but it does not expose the timing counters for a request executed by another client.
Therefore, a request performed with:
ollama run llama3.2does not allow a separate monitoring process to retrospectively recover:
prompt_eval_count
prompt_eval_duration
eval_count
eval_duration
Starting with v2.2, the project includes:
ollama-monitored-runUse it when you want the monitor to display metrics for the actual prompt you are executing, rather than for a separate synthetic benchmark.
Terminal 1:
ollama-monitorTerminal 2:
ollama-monitored-run llama3.2Then:
>>> Explain how a RAG pipeline works
...
>>> Now give me an example using SQL Server
...
The monitor will display:
llama3.2:latest state=done [actual prompt]
together with metrics for that exact request.
You can run a single monitored request:
ollama-monitored-run llama3.2 \
"Explain how the KV cache works."For a more repeatable benchmark:
ollama-monitored-run llama3.2 \
--tokens 256 \
--temperature 0 \
"Explain how transformer inference works."Starting with v2.2, automatic benchmarking is enabled by default.
It starts:
when the first active model is detected
when the model considered active changes
Normal startup:
ollama-monitorDisable automatic benchmarking with:
ollama-monitor --no-auto-benchmarkThe explicit option is also available:
ollama-monitor --auto-benchmark-on-model-changeWhen several models are resident at the same time, /api/ps does not expose an explicit last used model field.
Starting with v2.1, the monitor watches changes to:
expires_at
to estimate which model was used most recently.
If the displayed benchmark belongs to a different model from the currently active model, it is marked:
STALE
Example:
qwen3.8:27B state=STALE
Benchmark belongs to qwen3.8:27B,
while the active model is llama3.2:latest.
Press 'b' to benchmark llama3.2:latest.
For meaningful comparisons, it is important to distinguish between cold and warm runs.
The model is not resident in RAM/VRAM before the request.
This is useful for measuring:
model load duration
startup latency
initial TTFT
To explicitly unload a model, send a request with:
keep_alive: 0
Then verify:
ollama psThe model should no longer appear.
The model is already resident in memory.
This is generally the most useful test for measuring steady-state inference performance.
When comparing CPU-only, an internal GPU, and an eGPU, keep the following conditions unchanged:
model
quantization
prompt
num_ctx
num_predict
temperature
driver
power profile
Recommended settings:
num_predict = 256
temperature = 0
Recommended sequence:
UNLOAD MODEL
↓
COLD RUN #1
↓
WARM RUN #1
↓
WARM RUN #2
↓
WARM RUN #3
For warm runs, use the median of the three results whenever possible.
Recommended metrics to record:
TTFT
Prompt tok/s
Generation tok/s
CPU/GPU residency
VRAM
GPU utilization
GPU temperature
Power draw
RAM
Swap
PCIe generation / width
Model load duration
Total request duration
| Configuration | TTFT | Prompt tok/s | Gen tok/s | VRAM | GPU % | Temp | Power |
|---|---|---|---|---|---|---|---|
| CPU only | - | - | - | - | - | - | - |
| Internal GPU | - | - | - | - | - | - | - |
| eGPU | - | - | - | - | - | - | - |
The monitor can connect to an Ollama server running on another host.
ollama-monitor \
--ollama-url http://192.168.1.50:11434Benchmark:
ollama-monitor \
--ollama-url http://192.168.1.50:11434 \
--benchmark qwen3.8:27BReal monitored prompt:
ollama-monitored-run \
--ollama-url http://192.168.1.50:11434 \
llama3.2You can also use:
export OLLAMA_HOST=http://192.168.1.50:11434ollama-monitor and ollama-monitored-run communicate through a small local JSON state file.
When available:
$XDG_RUNTIME_DIR/ollama-monitor-state.json
otherwise:
~/.cache/ollama-monitor/state.json
You can override the location with:
export OLLAMA_MONITOR_STATE=/path/to/state.jsonThe file only contains the metrics needed to update the benchmark panel.
Monitor:
python3 ollama-monitor.pyWrapper:
python3 ollama-monitored-run llama3.2Check:
ls -l ~/.local/bin/ollama-monitorThen:
export PATH="$HOME/.local/bin:$PATH"To make it permanent:
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
source ~/.bashrcCheck:
ls -l ~/.local/bin/ollama-monitored-runIf it is missing, reinstall the current version:
chmod +x install.sh
./install.shThen:
command -v ollama-monitored-runCheck:
curl http://127.0.0.1:11434/api/psand:
ollama psCheck directly:
nvidia-smiThe monitor will continue to display Ollama and system metrics, but NVIDIA-specific information will not be available.
The query field names exposed by nvidia-smi may vary between NVIDIA driver versions.
The monitor tries several commonly used variants.
If the driver does not expose the value, it is shown as unavailable.
Starting with v2.1, TTFT detection considers both:
thinking
and:
response
If the value still remains N/A, verify that the request actually produced streamed output and that you are running the latest monitor version.
Starting with v2.1, the monitor may display:
state=STALE
Press:
b
to benchmark the active model.
Alternatively, leave automatic benchmarking enabled.
With versions older than v2.2, this was expected when the prompt was executed through another client.
Starting with v2.2:
ollama-monitorautomatically starts a standard benchmark when it detects the first active model or a model change.
For metrics from the actual prompt, use:
ollama-monitored-run MODELFirst verify:
blackwell-egpu statusThe command should return valid JSON.
Starting with v2.2.2, if the command exists but returns an error, empty output, or invalid JSON, the monitor displays a diagnostic message instead of silently hiding the panel.
The monitor cannot retrospectively reconstruct token/s for a request already executed directly by:
ollama run
AnythingLLM
Open WebUI
another API client
unless the request passes through a wrapper or proxy capable of reading Ollama's final response counters.
ollama-monitored-run solves this for terminal requests executed through the wrapper.
A possible future architecture is an Ollama-compatible proxy:
Client
↓
Ollama Monitor Proxy
↓
Ollama
This would make it possible to collect metrics from external applications as well.
When several models are loaded, detecting the most recently used model by observing expires_at is an heuristic.
For exact request metrics, use:
ollama-monitored-runHTTP stream chunks do not necessarily correspond one-to-one with model tokens.
For this reason, the final:
Generation tok/s
value is calculated from Ollama's final runtime counters.
First version of the monitor.
- terminal TUI monitor;
GET /api/psintegration;- currently loaded Ollama model;
- model size;
- CPU/GPU residency;
- model VRAM residency;
- context length;
- unload countdown;
- quantization;
- parameter size;
- NVIDIA multi-GPU support;
- GPU utilization;
- memory-controller utilization;
- VRAM used / total;
- GPU temperature;
- power draw / limit;
- P-State;
- SM clock;
- memory clock;
- PCI bus ID;
- PCIe generation / width;
- NVIDIA driver version;
- CUDA processes;
- per-process VRAM;
- CPU utilization;
- CPU temperature;
- RAM usage;
- swap usage;
- load average;
- root filesystem usage;
- Ollama process monitoring;
- optional
blackwell-egpu statusintegration; - remote Ollama support;
- no external Python dependencies.
Introduced the integrated LLM benchmark.
TTFT;Prompt eval tok/s;Generation tok/s;- prompt token count;
- generated token count;
- prompt evaluation duration;
- model load duration;
- total Ollama duration;
- done reason;
- keyboard benchmark with
b; --benchmark MODEL;--benchmark-tokens;--benchmark-prompt;--benchmark-keep-alive.
Final token/s values are calculated from Ollama's own counters rather than by counting HTTP streaming chunks.
Improved handling of multiple simultaneously loaded models.
- detection of the most recently active model through
expires_atchanges; STALEstate when the displayed benchmark belongs to another model;bnow targets the active model rather than the first entry returned by/api/ps;--auto-benchmark-on-model-change;- TTFT support for reasoning models by considering
thinkingin addition toresponse.
A possible:
TTFT = N/A
with models that emitted thinking content before the final response.
Introduced monitoring of actual user prompts and improved automatic benchmarking.
- automatic benchmark enabled by default;
- benchmark when the first active model is detected;
- automatic benchmark when the active model changes;
--no-auto-benchmark;ollama-monitored-run;- monitored interactive chat mode;
- monitored one-shot mode;
- collection of actual
/api/chatrequest metrics; [actual prompt]state;- shared JSON state file between the wrapper and monitor;
OLLAMA_MONITOR_STATEenvironment variable.
A normal request such as:
ollama run MODELdoes not expose its request counters to a separate monitor process.
To collect exact metrics for the actual prompt, use:
ollama-monitored-run MODELor, in a future version, an Ollama-compatible proxy.
Hotfix for v2.2.
detect_active_model() now always returns:
(active_model, changed)
including when:
/api/psreturns no models;- the first model is detected;
- resident model state changes.
This fixes:
TypeError: cannot unpack non-iterable NoneType object
Restored and hardened blackwell-egpu support.
In v2.2.1, the optional blackwell-egpu status panel code was accidentally lost while consolidating v2.2/v2.2.1 changes.
As a result, the panel could not be displayed even when the command was installed and working correctly.
The panel:
── BLACKWELL eGPU ────────────────────────────────────────
can display, when available:
mode
wait
eGPU enclosure name
NVIDIA GPU name
PCIe link
GPU utilization
VRAM used / total
temperature
power draw
PCIe RX / TX
iGPU
Example supported input:
{"mode":3,"wait":0,"egpu":"AORUS RTX506T AI BOX","egpu2":"NVIDIA GeForce RTX 5060 Ti","link":"16GT/s (Gen4)","gpu_util":0,"pwr_curr":21.02,"vram_used":110,"vram_total":16311,"temp":49,"pcie_rx":339,"pcie_tx":317}The panel no longer filters by mode value. If blackwell-egpu status returns valid JSON, the panel is displayed for mode=3 as well.
If blackwell-egpu is present in PATH but:
- exits with a non-zero return code;
- produces no output;
- produces invalid JSON;
the monitor displays a diagnostic message instead of silently hiding the panel.
Added automatic deduplication for the BLACKWELL eGPU panel.
When blackwell-egpu status identifies the same GPU already displayed in the NVIDIA GPU panel, duplicate metrics are omitted from the BLACKWELL section:
GPU utilization
VRAM used / total
temperature
power
BLACKWELL-specific information remains visible:
mode
wait
eGPU enclosure
PCIe link
PCIe RX / TX
iGPU
Example:
── NVIDIA GPU ────────────────────────────────────────────
GPU 0 NVIDIA GeForce RTX 5060 Ti
GPU ...
VRAM ...
Temp ...
Power ...
── BLACKWELL eGPU ────────────────────────────────────────
NVIDIA GeForce RTX 5060 Ti (AORUS RTX506T AI BOX)
Same device as NVIDIA GPU 0 — GPU/VRAM/Temp/Power shown above
Mode 3 Wait 0 Link 16GT/s (Gen4)
PCIe RX/TX 12 / 1019
iGPU: Integrated GPU
Deduplication occurs only when the match with an NVIDIA GPU is unambiguous.
The monitor compares the normalized GPU model name and, when necessary, total VRAM.
If several identical NVIDIA GPUs are present and it is not possible to determine which one is the eGPU with confidence, the complete BLACKWELL panel remains visible to avoid hiding useful information.
Hotfix for v2.2.3.
Added the missing:
import rerequired by:
normalize_gpu_name()v2.2.3 could fail with:
NameError: name 're' is not defined
when rendering the BLACKWELL eGPU panel.
Automatic deduplication between NVIDIA GPU and BLACKWELL eGPU remains unchanged.
Packaging/execution hotfix for v2.2.4.
In v2.2.4, import re was accidentally inserted before the Python shebang:
import re
#!/usr/bin/env python3
When the file was launched directly as a command, Linux interpreted it as a shell script and produced errors such as:
import: not found
from: not found
Syntax error: "(" unexpected
v2.2.5 guarantees that the first line is always:
#!/usr/bin/env python3
and that import re is correctly placed inside the Python source.
install.sh now also runs:
ollama-monitor --help
ollama-monitored-run --helpafter installation so that shebang or execution errors are detected immediately.
v2.2.5 is the current consolidated release of the monitor.
Terminal 1:
ollama-monitorTerminal 2:
ollama-monitored-run llama3.2For benchmark comparisons:
ollama-monitored-run llama3.2 \
--tokens 256 \
--temperature 0 \
"Explain how transformer inference works."Repeat with other models or GPU configurations while keeping the prompt and test parameters unchanged.
Possible future work includes:
CSV / JSON benchmark history
time-series charts
GPU/VRAM/temperature/power peak tracking
automatic Cold + Warm benchmark suite
automatic median calculation for warm runs
Ollama-compatible /api/chat and /api/generate proxy
external client support
model comparison history
Markdown / HTML export
AMD ROCm support
Intel GPU support
Ollama Local LLM Monitor
Current version: 2.2.5
Platform target: Ubuntu/Linux
Runtime: Python 3
Ollama API: /api/ps, /api/generate, /api/chat
GPU monitoring: nvidia-smi