Ollama GPU usage validation

From Notes_Wiki

Home > Local system based AI tools > Ollama > Ollama GPU usage validation

Ollama GPU usage validation

  1. Verify `/etc/systemd/system/ollama.service` has below line:
    Environment="OLLAMA_FLASH_ATTENTION=1"
  2. Run below in one terminal to monitor GPU usage including processes using GPU
    watch nvidia-smi
  3. Run some model on second terminal such as:
    ollama run deepseek-r1:8b
  4. In nvidia-settings graphical output, click on GPU 0 - <GPU name> and see information about 'GPU Utilization:'
  5. In third terminal if you use “ollama ps” we can see how much of CPU is being used and how much GPU
    ollama ps
    NAME              ID              SIZE      PROCESSOR          UNTIL
    deepseek-r1:8b    28f8fd6cdc67    6.3 GB    35%/65% CPU/GPU    4 minutes from now


Home > Local system based AI tools > Ollama > Ollama GPU usage validation