# Ollama 指令整理 ## 1. 啟動與管理 Ollama 服務 ### 使用 Homebrew 啟動或重新啟動 Ollama(適用於 macOS) ```bash brew services start ollama # 啟動 Ollama 服務 brew services restart ollama # 重新啟動 Ollama 服務 ``` ### 使用 systemctl 重新啟動 Ollama(適用於 Linux) ```bash sudo systemctl restart ollama # 重新啟動 Ollama 服務 ``` ## 2. 測試 Ollama 服務是否回應 ### 透過 HTTP API 測試模型回應 ```bash curl -s -D - localhost:11434/api/chat -d '{"model":"qwen2.5:0.5b"}' ``` 此指令會向 Ollama 伺服器發送請求,確認模型是否能透過 HTTP 正常回應。
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up