连接 127.0.0.1:7890… 失败:拒绝连接

Q0:
为什么
wget http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtrainval_06-Nov-2007.tar
–2021-06-21 11:28:10-- http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtrainval_06-Nov-2007.tar
正在连接 127.0.0.1:7890… 失败:拒绝连接。

A0:
原因为代理模式出了问题或者是端口已经被占用
详情参考:
故事的大大仙之CentOS 7 wget 正在连接 127.0.0.1:8118… 失败:拒绝连接。
export | grep -i proxy
declare -x ALL_PROXY=“http://127.0.0.1:7890”
declare -x HTTPS_PROXY=“http://127.0.0.1:7890/”
declare -x HTTP_PROXY=“http://127.0.0.1:7890/”
declare -x NO_PROXY=“localhost,127.0.0.0/8,::1”
declare -x all_proxy=“http://127.0.0.1:7890”
declare -x http_proxy=“http://127.0.0.1:7890/”
declare -x https_proxy=“http://127.0.0.1:7890/”
declare -x no_proxy=“localhost,127.0.0.0/8,::1”
7890 端口已经被占用

Q1:
怎么解决?

A1:
操作为:
unset ALL_PROXY
unset HTTP_PROXY
unset all_proxy
unset http_proxy

Q2:
用完怎么恢复
A2:
sudo vim /etc/profile

export all_proxy=“http://127.0.0.1:7890/”
export ALL_PROXY=“http://127.0.0.1:7890/”
export HTTP_PROXY=“http://127.0.0.1:7890/”
export http_proxy=“http://127.0.0.1:7890/”
export HTTPS_PROXY=“https://127.0.0.1:7890/”
export https_proxy=“https://127.0.0.1:7890/”

source /etc/profile

  • 3
    点赞
  • 18
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值