![ubuntu 18.04 存储库未更新/无法使用 apt-get(无法连接到 xxxx:8080)](https://linux22.com/image/919232/ubuntu%2018.04%20%E5%AD%98%E5%82%A8%E5%BA%93%E6%9C%AA%E6%9B%B4%E6%96%B0%2F%E6%97%A0%E6%B3%95%E4%BD%BF%E7%94%A8%20apt-get%EF%BC%88%E6%97%A0%E6%B3%95%E8%BF%9E%E6%8E%A5%E5%88%B0%20xxxx%3A8080%EF%BC%89.png)
我登录 Ubuntu 并运行
sudo apt-get update
然后
Err:1 https ://download.docker .com/linux/ubuntu bionic InRelease
Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
Err:2 http ://ppa.launchpad .net/certbot/certbot/ubuntu bionic InRelease
Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
Err:3 http ://archive.ubuntu .com/ubuntu bionic InRelease
Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
Err:4 http ://archive.ubuntu .com/ubuntu bionic-security InRelease
Unable to connect to 10. 10.8.179:8080:
Err:5 http ://archive.ubuntu .com/ubuntu bionic-updates InRelease
Unable to connect to 10. 10.8.179:8080:
Reading package lists... Done
W: Failed to fetch http ://archive.ubuntu .com/ubuntu/dists/bionic/InRelease Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
W: Failed to fetch http ://archive.ubuntu.com/ubuntu/dists/bionic-security/InRelease Unable to connect to 10. 10.8.179:8080:
W: Failed to fetch http ://archive.ubuntu .com/ubuntu/dists/bionic-updates/InRelease Unable to connect to 10. 10.8.179:8080:
W: Failed to fetch https ://download.docker .com/linux/ubuntu/dists/bionic/InRelease Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
W: Failed to fetch http ://ppa.launchpad .net/certbot/certbot/ubuntu/dists/bionic/InRelease Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
W: Some index files failed to download. They have been ignored, or old ones used instead.
我已删除环境变量中的所有代理配置以及 /etc/apt/apt.conf.d/proxy.conf 和 /etc/apt/apt.conf 中的 apt 配置,但错误仍然出现。有什么方法可以修复我的 Ubuntu apt?
谢谢。
答案1
您遇到的所有五个错误,这些链接之间都有空格,首先检查您添加到系统的所有 PPA。ping
它们并确保它们正常工作,否则将其删除。
Err:1 https ://download.docker .com/linux/ubuntu bionic InRelease
Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
Err:2 http ://ppa.launchpad .net/certbot/certbot/ubuntu bionic InRelease
Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
Err:3 http ://archive.ubuntu .com/ubuntu bionic InRelease
Could not connect to 10. 10.8.179:8080 (10. 10.8.179). - connect (111: Connection refused)
Err:4 http ://archive.ubuntu .com/ubuntu bionic-security InRelease
Unable to connect to 10. 10.8.179:8080:
Err:5 http ://archive.ubuntu .com/ubuntu bionic-updates InRelease
Unable to connect to 10. 10.8.179:8080: