Conda Install Package Error[通俗易懂]

Conda Install Package Error[通俗易懂]问题:conda无法安装更新,报错内容如下:参考链接:condahttperrorhttpnonenoneforurlnoneAnaconda更新失败$condacreate-ntensorflowpython=3.5Fetchingpackagemetadata…….CondaHTTPError:HTTP000CONNECTIONFAILED


Jetbrains全系列IDE稳定放心使用

安利好朋友写的美食文牛排到底要点几分熟,我觉得写得真不错 ,有兴趣的朋友们可以点开看看哟!

CondaHTTPError: HTTP 000 CONNECTION FAILED for url

问题:conda无法安装更新,报错内容如下:

conda create -n tensorflow python=3.5

Fetching package metadata .......
CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud/linux-64/rpodata.json>
Elapsed: -

An HTTP error occurred when trying to retrieve this URL.
HTTP errors are often intermittent, and a simple retry will get you on your way.
ConnectTimeout(MaxRetryError("HTTPSConnectionPool(host='nanomirrors.tuna.tsinghua.edu.cn', port=443): Max retries exceded with url: /anaconda/cloud/linux-64/repodata.json (Caused by ConnectTimeoutError(<requests.packages.urllib3.connecton.VerifiedHTTPSConnection object at 0x7fb6d340dcc0>, 'Connection to nanomirrors.tuna.tsinghua.edu.cn timed out. (connct timeout=9.15)'))",),)

解决方法:

#首先先添加清华的镜像源
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --set show_channel_urls yes

#如果无法解决,则删除channels配置文件中部分内容

#具体操作如下:
#1、快速创建channels配置文件的备份(保险起见)
cp ~/.condarc{ 
   ,.bak}

#查看配置文件的内容
cat ~/.condarc.bak 
channels:
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
  - https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud
  - defaults
  - https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda
  - https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda/conda
  - bioconda
  - r
  - conda-forge
show_channel_urls: true

#2、删除部分内容
## 主要是删除此行: - defaults
#修改后配置文件的内容如下:
vim ~/.condarc
channels:
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
show_channel_urls: true

ProxyError: Conda cannot proceed due to an error in your proxy configuration

执行代码:conda install -c conda-forge r-seurat=4.0.4

当使用 conda install 安装软件时出现如下报错:

ProxyError: Conda cannot proceed due to an error in your proxy configuration.
Check for typos and other configuration errors in any '.netrc' file in your home directory,
any environment variables ending in '_PROXY', and any other system-wide proxy
configuration settings.

解决方案

$ echo $http_proxy
http://10.53.15.246:3128
$ echo $https_proxy
http://10.53.15.246:3128

然后修改配置文件 ~/.condarc

修改后配置文件的内容如下:

$ cat ~/.condarc
channels:
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
  - r
  - conda-forge
show_channel_urls: true
proxy_servers:
  http: http://10.53.15.246:3128
  https: http://10.53.15.246:3128
ssl_verify: false
版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/187241.html原文链接:https://javaforall.net

赞 (0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • 解决windowlocationhref不跳转的 BUG「建议收藏」

    解决windowlocationhref不跳转的 BUG「建议收藏」今晚写了代码发现了一个小BUG,记录下。&lt;form&gt;———&lt;p&gt;&lt;!–下面按钮–&gt;&lt;divclass="footerContainer"&gt;&lt;buttonid="nextStep"onclick="skip()&q

    2022年7月15日
  • Java| 编译和反编译

    Java| 编译和反编译原文链接:http://www.yveshe.com/articles/2018/05/01/1525172129089.html什么是编程语言?在介绍编译和反编译之前,我们先来简单介绍下编程语言(ProgrammingLanguage)。编程语言(ProgrammingLanguage)分为低级语言(Low-levelLanguage)和高级语言(High-levelLa…

    2022年6月10日
  • 网闸上数据库同步

    网闸上数据库同步最近要实施数据库架构调整。1.数据库服务器要加台内网服务器,使用网闸隔离。中间有台文件中转服务器。要求实现数据库复制到内网服务器上供应用使用。考虑的方案有如下: 1.使用中转服务器作复制桥接。先从外网服务器同步到中转服务器,再同步到内网服务器。 2.貌似有的网闸产品支持数据库同步,如果本次上的产品支持,就不用什么桥接了,直接复制到内网服务器就OK了。  等待方案确认中

    2022年9月1日
  • 苹果x充电慢是什么原因_iPhone 12支持15W MagSafe无线充电,未来苹果手机的充电会发生什么?_充电器…

    2020-10-2122:44:400点赞0收藏0评论2020年由于一些特殊的原因导致一切似乎都和平时不一样了,所有的发布会都改成了线上,而备受关注的苹果也将发布会转移到了线上并采用录播的形式播出,从WWDC2020开始,我们就看到了一个不一样的线上发布会。众所周知,每年的秋季苹果都会发布新iPhone。在2020年9月份的苹果发布会上我们只见到了新iPad和新的AppleWatch发布,有且…

    2022年4月7日
  • vuethink 配置

    vuethink 配置

    2021年10月11日
  • 女生做java开发最多做几年,附赠复习资料

    女生做java开发最多做几年,附赠复习资料前言疫情过去,真正的春暖花开又回来了,时不时的可以和朋友约个饭,感慨今年的工作竞争压力很大,工作很不好找。作为一个开发人员,你是否面上了理想的公司,拿到了理想中的薪资?作为程序员,跳槽就是最好的涨薪方式。前提当然是你有足够实力,而不是只会纸上谈兵。面试准备不充分,就是浪费时间,更是对自己不负责任。今天给大家分享一份由粉丝投稿,我精心整理出来的一份1200页Java架构面试专题(文末见面试答案),绝大部分都是一线大厂的面试真题,可以根据这份面试专题查漏补缺,希望能够帮助你尽快找到工作!kafka面试基

    2022年7月7日

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号