Err:1 http://us.archive.ubuntu.com/ubuntu cosmic InRelease
Could not connect to 127.0.0.1:8118 (127.0.0.1). - connect (111: Connection refused)
Err:2 http://us.archive.ubuntu.com/ubuntu cosmic-proposed InRelease
Unable to connect to 127.0.0.1:8118:
Err:3 http://us.archive.ubuntu.com/ubuntu cosmic-updates InRelease
Unable to connect to 127.0.0.1:8118:
Err:4 http://us.archive.ubuntu.com/ubuntu cosmic-backports InRelease
Unable to connect to 127.0.0.1:8118:
Err:5 http://archive.canonical.com/ubuntu trusty InRelease
Could not connect to 127.0.0.1:8118 (127.0.0.1). - connect (111: Connection refused)
Err:6 http://archive.canonical.com/ubuntu bionic InRelease
Unable to connect to 127.0.0.1:8118:
答案1
无法连接到 127.0.0.1:8118:
这表明您配置了某种类型的代理。该代理处于离线状态,无法访问,并且由于apt
配置为通过该代理(该代理处于离线状态),因此您无法下载软件包。
您需要深入研究您的/etc/apt/apt.conf.d/*
设置文件以查看代理的定义位置,并尝试停用代理要求;如果仍然不起作用,那么您需要弄清楚是否必须运行该代理才能访问互联网以进行更新、互联网流量等。