所以我的 /boot 已经满了,现在我把一切都搞乱了。我真正想做的是运行sudo apt-get purge linux-image-3.2.0-{35,36,37,38}
,但我需要先解决这些其他问题。所以当我运行sudo apt-get -f install
我得到了这个(对于任何其他 apt-get 命令,我也得到了类似的输出)
$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following extra packages will be installed:
linux-generic-pae
The following packages will be upgraded:
linux-generic-pae
1 upgraded, 0 newly installed, 0 to remove and 192 not upgraded.
1 not fully installed or removed.
Need to get 0 B/1,726 B of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]?
dpkg: dependency problems prevent configuration of linux-generic-pae:
linux-generic-pae depends on linux-image-generic-pae (= 3.2.0.41.49); however:
Version of linux-image-generic-pae on system is 3.2.0.53.63.
linux-generic-pae depends on linux-headers-generic-pae (= 3.2.0.41.49); however:
Version of linux-headers-generic-pae on system is 3.2.0.53.63.
dpkg: error processing linux-generic-pae (--configure):
dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
Errors were encountered while processing:
linux-generic-pae
E: Sub-process /usr/bin/dpkg returned an error code (1)
但这并不能充分说明另一个错误是什么。我认为它是在我运行时sudo apt-get -f install
/boot 中只有大约 20MB 的可用空间时开始的。哎呀,/boot 分区真是太烦人了。
答案1
为什么不使用 Debian 包管理系统 -软件包?
使用以下命令删除旧内核即可:
# dpkg -P linux-image-3.2.0-{35,36,37,38}*
答案2
好的,在这里找到了解决方案:https://askubuntu.com/a/183625/7945
我需要/var/lib/dpkg/status
手动编辑并删除linux-generic-pae
包,然后我才能运行清除命令,然后我才能重新安装linux-generic-pae
。我这样做sudo apt-get install --reinstall linux-generic-pae
只是为了确保万无一失。