ollama - 💡(How to fix) Fix Mac ollama does not set menu bar item so you cannot close it without killing the process [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
ollama/ollama#14628Fetched 2026-04-08 00:33:37
View on GitHub
Comments
0
Participants
1
Timeline
1
Reactions
1
Participants
Timeline (top)
labeled ×1
RAW_BUFFERClick to expand / collapse

What is the issue?

If i close ollama using the GUI the processes stay in place. There is no dock item so I cannot kill it via the dock and always have to kill it via the process. This is cumbersome.

Relevant log output

OS

macOS

GPU

Apple

CPU

Apple

Ollama version

0.17.4

extent analysis

Fix Plan

The fix involves modifying the Ollama application to properly handle the quit event and terminate its processes when closed via the GUI.

Steps to Fix

  • Modify the Ollama application code to listen for the SIGTERM signal and handle it by terminating the process.
  • Add a atexit handler to ensure that the process is terminated when the GUI is closed.

Example Code

import atexit
import os
import signal
import sys

def terminate_process():
    # Terminate the process
    os._exit(0)

# Handle SIGTERM signal
def signal_handler(sig, frame):
    terminate_process()

# Register signal handler
signal.signal(signal.SIGTERM, signal_handler)

# Register atexit handler
atexit.register(terminate_process)

Verification

To verify that the fix worked, close the Ollama application via the GUI and check that the processes are terminated. You can use the ps command to check if the processes are still running.

Extra Tips

  • Make sure to test the fix on different macOS versions to ensure compatibility.
  • Consider adding a logging mechanism to track when the SIGTERM signal is received and when the process is terminated.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

ollama - 💡(How to fix) Fix Mac ollama does not set menu bar item so you cannot close it without killing the process [1 participants]