conda 环境报错如下:

(base) root@dell:/home/yuanzefu/llama# conda create -n llama2
Collecting package metadata (current_repodata.json): done
Solving environment: done

CondaSSLError: Encountered an SSL error. Most likely a certificate verification issue.

Exception: HTTPSConnectionPool(host='repo.anaconda.com', port=443): Max retries exceeded with url: /pkgs/main/linux-64/current_repodata.json (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:997)')))

网上找到的参考链接,可以根据链接配置一下 proxy_servers 和 ssl_varify。

https://stackoverflow.com/questions/31729076/conda-ssl-error

如果问题解决不了,查看一下环境变量。如果你本地的代理没有启动 https,那把 https 的链接改为 http。

cat ~/.condarc

proxy_servers:
  http: http://127.0.0.1:1234
  https: https://127.0.0.1:1234
ssl_verify: false
channel_priority: flexible
channels:
  - http://repo.anaconda.com/pkgs/main
  - defaults

proxy_servers:
  http: http://127.0.0.1:1234
  https: http://127.0.0.1:1234
ssl_verify: false
channel_priority: flexible
channels:
  - http://repo.anaconda.com/pkgs/main
  - defaults

End~

Logo

旨在为数千万中国开发者提供一个无缝且高效的云端环境,以支持学习、使用和贡献开源项目。

更多推荐