尽管 yum 似乎能够成功访问代理,但我还是不断收到 yum 代理连接失败错误 407。
我有以下运行 yum 的日志,其中包含最高的调试和错误执行list packages
命令:
# yum -d 10 -e 10 --rpmverbosity debug --enablerepo=\* list packages
Not loading "rhnplugin" plugin, as it is disabled
Loading "product-id" plugin
Loading "security" plugin
Loading "subscription-manager" plugin
Running "config" handler for "security" plugin
Running "config" handler for "subscription-manager" plugin
Updating Subscription Management repositories.
Proxy connection failed: 407
Config time: 0.202
Yum Version: 3.2.29
COMMAND: yum -d 10 -e 10 --rpmverbosity debug --enablerepo=* list packages
Installroot: /
Ext Commands:
packages
Setting up Package Sacks
epel-debuginfo/metalink | 2.4 kB 00:00
epel-debuginfo | 3.0 kB 00:00
epel-debuginfo/primary_db | 675 kB 00:00
epel-source/metalink | 2.4 kB 00:00
epel-source | 3.5 kB 00:00
epel-source/primary_db | 1.8 MB 00:00
epel-testing/metalink | 3.0 kB 00:00
Using older repomd.xml
Latest: Sat May 6 05:04:26 2017
Using: Fri May 5 22:12:48 2017
epel-testing | 4.3 kB 00:00
epel-testing/primary_db | 362 kB 00:00
epel-testing-debuginfo/metalink | 3.0 kB 00:00
epel-testing-debuginfo | 3.0 kB 00:00
epel-testing-debuginfo/primary_db | 22 kB 00:00
epel-testing-source/metalink | 3.0 kB 00:00
epel-testing-source | 3.5 kB 00:00
epel-testing-source/primary_db | 90 kB 00:00
rhel-source | 2.6 kB 00:00 ...
rhel-source/primary_db | 2.0 MB 00:04 ...
rhel-source-beta | 1.3 kB 00:00 ...
rhel-source-beta/primary | 214 B 00:00 ...
rpmfusion-free-updates-debuginfo | 3.0 kB 00:00
rpmfusion-free-updates-debuginfo/primary_db | 16 kB 00:00
rpmfusion-free-updates-source | 3.0 kB 00:00
rpmfusion-free-updates-source/primary_db | 30 kB 00:00
rpmfusion-free-updates-testing | 3.6 kB 00:00
rpmfusion-free-updates-testing/primary_db | 1.3 kB 00:00
rpmfusion-free-updates-testing-debuginfo | 3.0 kB 00:00
rpmfusion-free-updates-testing-debuginfo/primary_db | 1.3 kB 00:00
rpmfusion-free-updates-testing-source | 2.9 kB 00:00
rpmfusion-free-updates-testing-source/primary_db | 1.3 kB 00:00
rpmfusion-nonfree-updates-debuginfo | 3.0 kB 00:00
rpmfusion-nonfree-updates-debuginfo/primary_db | 4.9 kB 00:00
rpmfusion-nonfree-updates-source | 3.0 kB 00:00
rpmfusion-nonfree-updates-source/primary_db | 7.3 kB 00:00
rpmfusion-nonfree-updates-testing | 3.6 kB 00:00
rpmfusion-nonfree-updates-testing/primary_db | 1.3 kB 00:00
rpmfusion-nonfree-updates-testing-debuginfo | 3.0 kB 00:00
rpmfusion-nonfree-updates-testing-debuginfo/primary_db | 1.3 kB 00:00
rpmfusion-nonfree-updates-testing-source | 2.9 kB 00:00
rpmfusion-nonfree-updates-testing-source/primary_db | 1.3 kB 00:00
webtatic-archive | 2.9 kB 00:00
webtatic-archive/primary_db 92% [=========================================================== ] 343 kB/s | 2.3 MB 00:00 ETA
忽略此错误可以吗?yum 的功能是否受到了影响?如果是,我该如何修复?
我已经通过环境变量(http_proxy、ftp_proxy 等)以及通过以下方式正确配置了代理/etc/yum.conf
我知道代理配置是正确的,因为 yum 能够像上面一样列出软件包。甚至还有一个进度条反映下载情况。
答案1
尝试删除代理/yum.conf 代理条目等的环境变量,并在 /etc/rhsm/rhsm.conf 中输入代理详细信息。