无法将内核更新至 2.6.35.27

无法将内核更新至 2.6.35.27

当我尝试更新时,我得到了消息,我猜我这里遗漏了一些东西?

Filesystem    Type     Size   Used  Avail Use% Mounted on
/dev/sdb6     ext4      43G   7.7G    33G  20% /
none      devtmpfs     1.6G   349k   1.6G   1% /dev
none         tmpfs     1.6G   5.9M   1.6G   1% /dev/shm
none         tmpfs     1.6G   218k   1.6G   1% /var/run
none         tmpfs     1.6G      0   1.6G   0% /var/lock
/dev/sdb2  fuseblk     258G   198G    60G  77% /media/Backup
/dev/sda1  fuseblk     321G   175G   146G  55% /media/Media
/dev/sdb1     ext4      96M    84M   6.7M  93% /boot
/dev/sdb7     ext4     175G    81G    86G  49% /home

输出如下:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages will be REMOVED:
linux-image-2.6.35-22-generic
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
5 not fully installed or removed.
After this operation, 107MB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 282211 files and directories currently installed.)
Removing linux-image-2.6.35-22-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 2.6.35-22-generic   /boot/vmlinuz-2.6.35-22-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 2.6.35-22-generic /boot/vmlinuz-2.6.35-22-generic
/etc/default/grub: 23: Syntax error: newline unexpected
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 2
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-2.6.35-22-  generic.postrm line 328.
dpkg: error processing linux-image-2.6.35-22-generic (--remove):
subprocess installed post-removal script returned error exit status 1
Errors were encountered while processing:
linux-image-2.6.35-22-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)

以下是etc/default/grub 的内容

答案1

您在(内核存储位置)没有足够的空间/boot来继续操作。您需要分配更多空间/boot才能继续。通常每个内核需要大约 17M 的空间。

您可以删除较旧的内核安装(有时使用sudo apt-get autoremove)或直接卸载特定版本的内核。强烈建议您保留至少两个可用的内核版本,以防较新的内核出现问题。

答案2

正如日志所述

gzip: stdout: No space left on device

根分区上可能缺少空间。您可以检查一下或提供输出吗df -Th

编辑1:

至于dpkg错误:

文件中存在语法错误/etc/default/grub。请更正它或在此处发布。

编辑2:

第 23 行/etc/default/grub不应该如下所示:

GRUB_GFXMODE=>>1024x768-24<<

但像这样:

GRUB_GFXMODE=1024x768

相关内容