2

EDIT: following the instructions on this thread, I attempted to remove my old/unused kernels but could not. It looks like there's not enough space for the operation, what do I do?

Output of ls /boot/:

abi-4.2.0-42-generic         initrd.img-4.4.0-57-generic
abi-4.4.0-45-generic         lost+found
abi-4.4.0-47-generic         memtest86+.bin
abi-4.4.0-51-generic         memtest86+.elf
config-4.2.0-42-generic      memtest86+_multiboot.bin
config-4.4.0-45-generic      System.map-4.2.0-42-generic
config-4.4.0-47-generic      System.map-4.4.0-45-generic
config-4.4.0-51-generic      System.map-4.4.0-47-generic
grub                         System.map-4.4.0-51-generic
initrd.img-4.2.0-42-generic  vmlinuz-4.2.0-42-generic
initrd.img-4.4.0-42-generic  vmlinuz-4.4.0-45-generic
initrd.img-4.4.0-45-generic  vmlinuz-4.4.0-47-generic
initrd.img-4.4.0-47-generic  vmlinuz-4.4.0-51-generic
initrd.img-4.4.0-51-generic

Output of dpkg -l linux-image-\* | grep ^ii

ii  linux-image-4.2.0-42-generic       4.2.0-42.49  amd64        Linux kernel image for version 4.2.0 on 64 bit x86 SMP 
ii  linux-image-4.4.0-45-generic       4.4.0-45.66  amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP 
ii  linux-image-4.4.0-47-generic       4.4.0-47.68  amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP 
ii  linux-image-4.4.0-51-generic       4.4.0-51.72  amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP 
ii  linux-image-extra-4.2.0-42-generic 4.2.0-42.49  amd64        Linux kernel extra modules for version 4.2.0 on 64 bit x86 SMP 
ii  linux-image-extra-4.4.0-45-generic 4.4.0-45.66  amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP

However, when I run sudo apt-get purge linux-image-4.2.0-42 linux-image-4.4.0-45, I get the following messages:

gzip: stdout: No space left on device
E: mkinitramfs failure cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-4.4.0-47-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
dpkg: error processing package linux-image-extra-4.4.0-47-generic (--remove):
 subprocess installed post-removal script returned error exit status 1
Errors were encountered while processing:
 linux-image-extra-4.4.0-47-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)

Am I doing something wrong?

ORIGINAL:

I've been getting space errors whenever I try to upgrade, and on the dist-upgrade I tried just now I got the following errors:

gzip: stdout: No space left on device
E: mkinitramfs failure find 141 cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-4.4.0-51-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
dpkg: error processing package linux-image-extra-4.4.0-51-generic (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 linux-image-extra-4.4.0-47-generic
 linux-image-extra-4.4.0-51-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)

The output of df is:

Filesystem                   1K-blocks     Used Available Use% Mounted on
udev                           1787060        0   1787060   0% /dev
tmpfs                           361572    10496    351076   3% /run
/dev/mapper/xubuntu--vg-root 236014344 38503396 185499020  18% /
tmpfs                          1807848      172   1807676   1% /dev/shm
tmpfs                             5120        4      5116   1% /run/lock
tmpfs                          1807848        0   1807848   0% /sys/fs/cgroup
/dev/sda1                       240972   227218      1313 100% /boot
tmpfs                           361572       36    361536   1% /run/user/1000

and the output of uname -r:

4.4.0-51-generic

I've tried several things based on solutions offered to some of these errors individually, but I haven't had any luck yet.

Thank you sincerely for any help!

J Clark
  • 21
  • 1
    /boot is full. – Pilot6 Jan 31 '17 at 15:16
  • That happened to me when I had a flirt with Debian, which put me off it immediately. It's strange to see how this could have happened in the standard installation of Ubuntu, unless you customized the partitioning. For the records, can you comment on how you installed Xubuntu? –  Jan 31 '17 at 15:32
  • If there's not enough space to even remove the kernel packages you could remove one or more of the /boot/initrd.img-* files that correspond to the kernel packages that you were about to remove, then proceed to remove the packages like before. I'm going to vote to reopen your question since it's slightly yet significantly different from the linked question. – David Foerster Feb 02 '17 at 15:24
  • sudo apt-get clean is the first command to run. – Pilot6 Feb 02 '17 at 19:21
  • Now dupe of http://askubuntu.com/questions/171209/my-boot-partition-hit-100-and-now-i-cant-upgrade-cant-remove-old-kernels-to – muru Feb 03 '17 at 01:22

0 Answers0