答案1
我看到您除了 Ubuntu 的默认源之外还添加了其他存储库。如果您可以保证您的互联网连接正常并且问题仍然存在,那么我相信这些存储库有问题。也许它们暂时离线,或者您的防火墙或代理阻止了它们。
部分解决此问题的一种方法是恢复默认存储库。首先,确保备份当前的 apt 配置文件
$ cd /etc/apt
$ sudo cp sources.list sources.list.old
$ sudo cp -r sources.list.d sources.list.d.old
现在,确保 /etc/apt/sources.list 仅包含以下内容:
deb http://br.archive.ubuntu.com/ubuntu/ xenial main restricted
deb-src http://br.archive.ubuntu.com/ubuntu/ xenial main restricted
deb http://br.archive.ubuntu.com/ubuntu/ xenial-updates main restricted
deb-src http://br.archive.ubuntu.com/ubuntu/ xenial-updates main restricted
deb http://br.archive.ubuntu.com/ubuntu/ xenial universe
deb-src http://br.archive.ubuntu.com/ubuntu/ xenial universe
deb http://br.archive.ubuntu.com/ubuntu/ xenial-updates universe
deb-src http://br.archive.ubuntu.com/ubuntu/ xenial-updates universe
deb http://br.archive.ubuntu.com/ubuntu/ xenial multiverse
deb-src http://br.archive.ubuntu.com/ubuntu/ xenial multiverse
deb http://br.archive.ubuntu.com/ubuntu/ xenial-updates multiverse
deb-src http://br.archive.ubuntu.com/ubuntu/ xenial-updates multiverse
deb http://br.archive.ubuntu.com/ubuntu/ xenial-backports main restricted universe multiverse
deb-src http://br.archive.ubuntu.com/ubuntu/ xenial-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu xenial-security main restricted
deb-src http://security.ubuntu.com/ubuntu xenial-security main restricted
deb http://security.ubuntu.com/ubuntu xenial-security universe
deb-src http://security.ubuntu.com/ubuntu xenial-security universe
deb http://security.ubuntu.com/ubuntu xenial-security multiverse
deb-src http://security.ubuntu.com/ubuntu xenial-security multiverse
deb http://archive.canonical.com/ubuntu xenial partner
deb-src http://archive.canonical.com/ubuntu xenial partner
然后,从 /etc/apt/sources.list.d 中删除所有内容
$ sudo rm /etc/apt/sources.list.d/*
最后,更新并查看会发生什么:
$ sudo apt-get update && sudo apt-get dist-upgrade
如果一切正常,您将能够从标准 Ubuntu 发行版升级软件包。