每当我尝试更新时,它每次都会卡在 32% 并失败。
someone@somewhere:~/$ sudo apt update
Ign:1 http://linux.dropbox.com/ubuntu wily InRelease
Get:2 http://linux.dropbox.com/ubuntu wily Release [6,596 B]
Ign:3 http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 InRelease
Ign:4 http://dl.google.com/linux/chrome/deb stable InRelease
Get:5 http://linux.dropbox.com/ubuntu wily Release.gpg [473 B]
Hit:6 http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 Release
Hit:7 http://repo.steampowered.com/steam precise InRelease
Hit:8 http://ca.archive.ubuntu.com/ubuntu xenial InRelease
Get:10 http://security.ubuntu.com/ubuntu xenial-security InRelease [107 kB]
Hit:11 http://ppa.launchpad.net/freecad-maintainers/freecad-stable/ubuntu xenial InRelease
Hit:12 https://download.sublimetext.com apt/stable/ InRelease
Hit:13 http://dl.google.com/linux/chrome/deb stable Release
Hit:15 https://dl.winehq.org/wine-builds/ubuntu xenial InRelease
Get:16 http://ca.archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB]
Hit:18 http://ppa.launchpad.net/kubuntu-ppa/backports/ubuntu xenial InRelease
Hit:19 http://ppa.launchpad.net/webupd8team/java/ubuntu xenial InRelease
Get:14 http://ca.archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]
Hit:20 http://ppa.launchpad.net/wireshark-dev/stable/ubuntu xenial InRelease
Ign:21 http://ca.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages
Ign:22 http://ca.archive.ubuntu.com/ubuntu xenial-updates/main i386 Packages
Ign:23 http://ca.archive.ubuntu.com/ubuntu xenial-updates/main Translation-en
Get:24 http://ca.archive.ubuntu.com/ubuntu xenial-updates/main amd64 DEP-11 Metadata [320 kB]
Get:25 http://ca.archive.ubuntu.com/ubuntu xenial-updates/main DEP-11 64x64 Icons [227 kB]
Ign:26 http://ca.archive.ubuntu.com/ubuntu xenial-updates/restricted amd64 Packages
32% [Connecting to ca.archive.ubuntu.com (2001:67c:1560:8001::11)]
它阻止我升级包或更新包列表。
每当您不确定可能是什么问题时,
apt
或者apt-get
您可以查看日志文件以获取详细信息。这是一个相当笼统的答案,但它应该为您提供线索。默认情况下
apt-get
(apt) 日志可以在 中找到/var/log/apt/term.log
,如果您没有在apt-get
配置文件中进行其他设置。您还可以查看其他日志文件,例如
/var/log/apt/history.log
.文件
/var/log/dpkg.log
也是有效的检查,因为apt-get
它是基于dpkg
.基于周围的其他一些成功,
/etc/apt/sources.list
我开始在那里玩,发现如果我将服务器从更改ca.archive.ubuntu.com
为us.archive.ubuntu.com
它突然工作。加拿大服务器可能有问题?