dify 连接不上ollama An error occurred during credentials validation:

三大报错

An error occurred during credentials validation: HTTPConnectionPool(host='host.docker.internal', port=11434): Max retries exceeded with url: /api/chat (Caused by NameResolutionError("<urllib3.connection.HTTPConnection object at 0x7f26fc3c00b0>: Failed to resolve 'host.docker.internal' ([Errno -2] Name or service not known)"))

An error occurred during credentials validation: HTTPConnectionPool(host='192.168.1.100', port=11434): Max retries exceeded with url: /api/chat (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7f26fc23ea80>, 'Connection to 192.168.1.100 timed out. (connect timeout=10)'))

An error occurred during credentials validation: HTTPConnectionPool(host='172.17.0.1', port=11434): Max retries exceeded with url: /api/chat (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f26fcbce660>: Failed to establish a new connection: [Errno 111] Connection refused'))

真服了!!!

按照大家搜的,一般都能解决,

首先确保 自己的不是回环。

sudo netstat -tuln | grep 11434

输出为 tcp 什么 127.0.0.1 这个就不行

输出为tcp6 0 0 :::11434 :::* LISTEN

这个 就可以

先停止 参考https://zhuanlan.zhihu.com/p/23168996538

复制代码
systemctl stop ollama

后启动

OLLAMA_HOST=0.0.0.0 nohup ollama serve > ollama.log 2>&1 &

又是浪费5个小时的狗血经历

相关推荐
大模型实验室Lab4AI5 小时前
LLama-Factory官方课程答疑汇总+课程内容升级(多模态实战)
llama
范桂飓1 天前
LLaMA-Factory 大模型微调平台
人工智能·llama
杜子不疼.2 天前
【大模型 】API 对接指南:OpenAI/Claude/LLaMA 3 调用技巧
llama
小Pawn爷2 天前
11.大模型评估
llm·llama·fingpt
薛定谔的猫19824 天前
LlamaIndex(一)初见
llama·llamaindex
Android小码家6 天前
llama.cpp+Android应用定制
android·llama
Android小码家6 天前
WSL+llama+CPU本地模型部署
llama·wsl·模型
沛沛老爹6 天前
Web开发者5分钟上手:Agent Skills环境搭建与基础使用实战
java·人工智能·llm·llama·rag·agent skills
星辰引路-Lefan6 天前
在浏览器中运行大模型:基于 WebGPU 的本地 LLM 应用深度解析
ai·ai编程·llama·gpu算力
natide7 天前
text-generateion-webui模型加载器(Model Loaders)选项
人工智能·llama