我正在通过终端运行升级(12.10 到 13.04),但它一直卡在这儿:
Failed to lock /var/cache/apt/archives/lock
我该怎么办?我有 root 权限。除了全新安装,我不知道还能尝试什么。
Checking package manager
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
Calculating the changes
Calculating the changes
Do you want to start the upgrade?
3 packages are going to be removed. 155 new packages are going to be
installed. 1204 packages are going to be upgraded.
You have to download a total of 595 M. This download will take about
1 hour 15 minutes with a 1Mbit DSL connection and about 23 hours with
a 56k modem.
Fetching and installing the upgrade can take several hours. Once the
download has finished, the process cannot be canceled.
Continue [yN] Details [d]y
Fetching
Could not download the upgrades
The upgrade has aborted. Please check your Internet connection or
installation media and try again. All files downloaded so far have
been kept.
Failed to lock /var/cache/apt/archives/lock
Restoring original system state
Aborting
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
root@chaitanya-XPS-Ubuntu:~#
答案1
我遇到过这种情况。这是因为您打开了一个包管理器。查看您是否打开了 synaptic 或其他 apt,然后将其关闭。此外,如果您同时运行 GUI 更新管理器,它也会给您同样的错误。