[SOLVED] Update error caused by "No space left on device"

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
moho70

[SOLVED] Update error caused by "No space left on device"

Post by moho70 »

Good morning

I'm having problems updating my Linux Mint 18.3, Cinnamon 64-bit edition, I'm an average user. The system is protected with the mint built in encryption software on startup.

The updates are loaded and when I want install them, it says in the first error window:

Code: Select all

E: linux-image-extra-4.13.0-31-generic: subprocess installed post-removal script returned error exit status 1
and in the next error window:

Code: Select all

Razširjanje predlog iz paketov: 100%
Prednastavljanje paketov ...
(Reading database ... 519396 files and directories currently installed.)
Removing linux-image-extra-4.13.0-31-generic (4.13.0-31.34~16.04.1) ...
depmod: FATAL: could not load /boot/System.map-4.13.0-31-generic: No such file or directory
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.13.0-31-generic /boot/vmlinuz-4.13.0-31-generic
run-parts: executing /etc/kernel/postinst.d/dkms 4.13.0-31-generic /boot/vmlinuz-4.13.0-31-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.13.0-31-generic /boot/vmlinuz-4.13.0-31-generic
update-initramfs: Generating /boot/initrd.img-4.13.0-31-generic
Warning: No support for locale: sl_SI.utf8
depmod: WARNING: could not open /var/tmp/mkinitramfs_Fa5MRq/lib/modules/4.13.0-31-generic/modules.order: No such file or directory
depmod: WARNING: could not open /var/tmp/mkinitramfs_Fa5MRq/lib/modules/4.13.0-31-generic/modules.builtin: No such file or directory

gzip: stdout: No space left on device
E: mkinitramfs failure cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-31-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
dpkg: error processing package linux-image-extra-4.13.0-31-generic (--remove):
 subprocess installed post-removal script returned error exit status 1
Errors were encountered while processing:
 linux-image-extra-4.13.0-31-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)
Neuspešna namestitev paketa. Poteka poskus obnove namestitve:
Setting up initramfs-tools (0.122ubuntu8.10) ...
update-initramfs: deferring update (trigger activated)
Setting up linux-image-extra-4.13.0-26-generic (4.13.0-26.29~16.04.2) ...
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.13.0-26-generic /boot/vmlinuz-4.13.0-26-generic
run-parts: executing /etc/kernel/postinst.d/dkms 4.13.0-26-generic /boot/vmlinuz-4.13.0-26-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.13.0-26-generic /boot/vmlinuz-4.13.0-26-generic
update-initramfs: Generating /boot/initrd.img-4.13.0-26-generic
Warning: No support for locale: sl_SI.utf8

gzip: stdout: No space left on device
cpio: write error: Broken pipe
find: ‘standard output’: Broken pipe
find: write error
E: mkinitramfs failure find 1 cpio 1 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-26-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
dpkg: error processing package linux-image-extra-4.13.0-26-generic (--configure):
 subprocess installed post-installation script returned error exit status 1
Setting up linux-firmware (1.157.15) ...
update-initramfs: Generating /boot/initrd.img-4.13.0-26-generic
Warning: No support for locale: sl_SI.utf8

gzip: stdout: No space left on device
cpio: write error: Broken pipe
find: ‘standard output’: Broken pipe
find: write error
E: mkinitramfs failure find 1 cpio 1 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-26-generic with 1.
dpkg: error processing package linux-firmware (--configure):
 subprocess installed post-installation script returned error exit status 1
Processing triggers for initramfs-tools (0.122ubuntu8.10) ...
update-initramfs: Generating /boot/initrd.img-4.13.0-26-generic
Warning: No support for locale: sl_SI.utf8

gzip: stdout: No space left on device
cpio: write error: Broken pipe
find: ‘standard output’: Broken pipe
find: write error
E: mkinitramfs failure find 1 cpio 1 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-26-generic with 1.
dpkg: error processing package initramfs-tools (--configure):
 subprocess installed post-installation script returned error exit status 1
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 4 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: Update error

Post by catweazel »

moho70 wrote: Sat Feb 17, 2018 4:21 am

Code: Select all

gzip: stdout: No space left on device
gzip: stdout: No space left on device
gzip: stdout: No space left on device
gzip: stdout: No space left on device
That's the problem. You've probably got a separate boot partition and it's full. You're going to have to remove some old kernels.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
moho70

Re: Update error

Post by moho70 »

Thank you for the quick reply...
I thought about that, so I went into the update manager and try to remove/unistall some old installed kernels, but the problem is, they are not unistalled, they just keep there installed ???

The error is similar as the update:

Code: Select all

(Reading database ... 519396 files and directories currently installed.)
Removing linux-image-extra-4.13.0-31-generic (4.13.0-31.34~16.04.1) ...
depmod: FATAL: could not load /boot/System.map-4.13.0-31-generic: No such file or directory
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.13.0-31-generic /boot/vmlinuz-4.13.0-31-generic
run-parts: executing /etc/kernel/postinst.d/dkms 4.13.0-31-generic /boot/vmlinuz-4.13.0-31-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.13.0-31-generic /boot/vmlinuz-4.13.0-31-generic
update-initramfs: Generating /boot/initrd.img-4.13.0-31-generic
Warning: No support for locale: sl_SI.utf8
depmod: WARNING: could not open /var/tmp/mkinitramfs_y8T0lx/lib/modules/4.13.0-31-generic/modules.order: No such file or directory
depmod: WARNING: could not open /var/tmp/mkinitramfs_y8T0lx/lib/modules/4.13.0-31-generic/modules.builtin: No such file or directory

gzip: stdout: No space left on device
E: mkinitramfs failure cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-31-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
dpkg: error processing package linux-image-extra-4.13.0-31-generic (--remove):
 subprocess installed post-removal script returned error exit status 1
Errors were encountered while processing:
 linux-image-extra-4.13.0-31-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)
Neuspešna namestitev paketa. Poteka poskus obnove namestitve:
Setting up initramfs-tools (0.122ubuntu8.10) ...
update-initramfs: deferring update (trigger activated)
Setting up linux-image-extra-4.13.0-26-generic (4.13.0-26.29~16.04.2) ...
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.13.0-26-generic /boot/vmlinuz-4.13.0-26-generic
run-parts: executing /etc/kernel/postinst.d/dkms 4.13.0-26-generic /boot/vmlinuz-4.13.0-26-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.13.0-26-generic /boot/vmlinuz-4.13.0-26-generic
update-initramfs: Generating /boot/initrd.img-4.13.0-26-generic
Warning: No support for locale: sl_SI.utf8

gzip: stdout: No space left on device
cpio: write error: Broken pipe
find: ‘standard output’: Broken pipe
find: write error
E: mkinitramfs failure find 1 cpio 1 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-26-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
dpkg: error processing package linux-image-extra-4.13.0-26-generic (--configure):
 subprocess installed post-installation script returned error exit status 1
Setting up linux-firmware (1.157.15) ...
update-initramfs: Generating /boot/initrd.img-4.13.0-26-generic
Warning: No support for locale: sl_SI.utf8

gzip: stdout: No space left on device
cpio: write error: Broken pipe
find: ‘standard output’: Broken pipe
find: write error
E: mkinitramfs failure find 1 cpio 1 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-26-generic with 1.
dpkg: error processing package linux-firmware (--configure):
 subprocess installed post-installation script returned error exit status 1
Processing triggers for initramfs-tools (0.122ubuntu8.10) ...
update-initramfs: Generating /boot/initrd.img-4.13.0-26-generic
Warning: No support for locale: sl_SI.utf8

gzip: stdout: No space left on device
cpio: write error: Broken pipe
find: ‘standard output’: Broken pipe
find: write error
E: mkinitramfs failure find 1 cpio 1 gzip 1
update-initramfs: failed for /boot/initrd.img-4.13.0-26-generic with 1.
dpkg: error processing package initramfs-tools (--configure):
 subprocess installed post-installation script returned error exit status 1
Last edited by karlchen on Sat Feb 17, 2018 7:40 pm, edited 1 time in total.
Reason: added code tags where appropriate
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: Update error

Post by catweazel »

Please post the output of this terminal command:

Code: Select all

ls /boot
Enclose the results in code markers "</>", which you can select from the mini toolbar above the textbox where you type your reply.

Do the same with this command:

Code: Select all

df -h
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
moho70

Re: Update error

Post by moho70 »

I hope I understood, what you meant with the quotes:

Code: Select all

 ls /boot
abi-4.10.0-33-generic         initrd.img-4.10.0-42-generic
abi-4.10.0-35-generic         initrd.img-4.13.0-26-generic
abi-4.10.0-37-generic         initrd.img-4.8.0-53-generic
abi-4.10.0-38-generic         lost+found
abi-4.10.0-40-generic         memtest86+.bin
abi-4.10.0-42-generic         memtest86+.elf
abi-4.13.0-26-generic         memtest86+_multiboot.bin
abi-4.8.0-53-generic          System.map-4.10.0-33-generic
config-4.10.0-33-generic      System.map-4.10.0-35-generic
config-4.10.0-35-generic      System.map-4.10.0-37-generic
config-4.10.0-37-generic      System.map-4.10.0-38-generic
config-4.10.0-38-generic      System.map-4.10.0-40-generic
config-4.10.0-40-generic      System.map-4.10.0-42-generic
config-4.10.0-42-generic      System.map-4.13.0-26-generic
config-4.13.0-26-generic      System.map-4.8.0-53-generic
config-4.8.0-53-generic       vmlinuz-4.10.0-33-generic
efi                           vmlinuz-4.10.0-35-generic
grub                          vmlinuz-4.10.0-37-generic
initrd.img-4.10.0-33-generic  vmlinuz-4.10.0-38-generic
initrd.img-4.10.0-35-generic  vmlinuz-4.10.0-40-generic
initrd.img-4.10.0-37-generic  vmlinuz-4.10.0-42-generic
initrd.img-4.10.0-38-generic  vmlinuz-4.13.0-26-generic
initrd.img-4.10.0-40-generic  vmlinuz-4.8.0-53-generic 

Code: Select all

df -h
Filesystem                 Size  Used Avail Use% Mounted on
udev                       3,9G     0  3,9G   0% /dev
tmpfs                      786M  9,6M  776M   2% /run
/dev/mapper/mint--vg-root  221G   76G  134G  36% /
tmpfs                      3,9G  202M  3,7G   6% /dev/shm
tmpfs                      5,0M  4,0K  5,0M   1% /run/lock
tmpfs                      3,9G     0  3,9G   0% /sys/fs/cgroup
/dev/sda2                  473M  462M     0 100% /boot
/dev/sda1                  511M  3,4M  508M   1% /boot/efi
cgmfs                      100K     0  100K   0% /run/cgmanager/fs
tmpfs                      786M   40K  786M   1% /run/user/1000
/home/robert/.Private      221G   76G  134G  36% /home/robert
/dev/sdb1                   60G   28G   32G  47% /media/robert/3431-65651
User avatar
Pjotr
Level 24
Level 24
Posts: 20129
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland) 🇳🇱
Contact:

Re: Update error

Post by Pjotr »

Try this:

1. Remove the 4.10 and the 4.8 kernel that are still installed. Update Manager - panel: View - Linux kernels.

2. Then do this:

Code: Select all

sudo rm -v /boot/vmlinuz-4.10*
3. Finally, ask yourself: given the fact that this is probably caused by full disk encryption (which creates a separate /boot): why did I encrypt my entire system in the first place? :wink:

Many people select full disk encryption without considering whether they really need it. If it's not needed, it's purely a disadvantage.
Tip: 10 things to do after installing Linux Mint 21.3 Virginia
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.
moho70

Re: Update error

Post by moho70 »

Pjotr wrote: Sat Feb 17, 2018 5:44 am Try this:

1. Remove the 4.10 and the 4.8 kernel that are still installed. Update Manager - panel: View - Linux kernels.

2. Then do this:

Code: Select all

sudo rm -v /boot/vmlinuz-4.10*
3. Finally, ask yourself: given the fact that this is probably caused by full disk encryption (which creates a separate /boot): why did I encrypt my entire system in the first place? :wink:

Many people select full disk encryption without considering whether they really need it. If it's not needed, it's purely a disadvantage.
Thank you for the help, but, as I wrote before, I can't remove any kernel, it doesn't work, then I tried with the code...same result: the kernels are still installed :?:
Regarding the encryption...why do we have two locks on the front door, why do we have a watchdog, alarm, etc...it is for being safe. Laptops are lucrative for burglars, for the hardware, but more because of the content...and we do have burglars around.
Anyway...the kernels are still installed and I still can't update Mint :?:
User avatar
Termy
Level 12
Level 12
Posts: 4248
Joined: Mon Sep 04, 2017 8:49 pm
Location: UK
Contact:

Re: Update error

Post by Termy »

Have you yet tried: sudo apt-get autoremove

Alternatively, a tool like roks could be useful. To get it, I recommend that you get the manager (to browse, install, uninstall, and optionally update) for various programs and files in my repositories, by running this one-liner:

Code: Select all

sudo wget -q https://github.com/terminalforlife/installit/raw/master/insit -O /usr/bin/insit && sudo chmod 755 /usr/bin/insit; sudo insit -S
Once that's done, you can use insit --help for usage information, or skip straight to installing roks with: sudo insit roks

Information and demonstration of insit can be found here and in various videos on YT.
I'm also Terminalforlife on GitHub.
moho70

Re: Update error caused by "No space left on device"

Post by moho70 »

The command

Code: Select all

sudo apt-get autoremove
worked, so I could clean afterwards all old kernels and the updates are installed now.
User avatar
Termy
Level 12
Level 12
Posts: 4248
Joined: Mon Sep 04, 2017 8:49 pm
Location: UK
Contact:

Re: Update error caused by "No space left on device"

Post by Termy »

Awesome. :) I recommend that you run that command every now and then, as it will clear out a lot of unnecessary packages which were marked as dependencies yet detected by APT as being no longer needed, kernels included. You may also want to run: sudo apt-get autoclean to save even more space. If you're not on a limited bandwith, you'll find the more aggressive sudo apt-get clean even more effective.
I'm also Terminalforlife on GitHub.
User avatar
Moem
Level 22
Level 22
Posts: 16233
Joined: Tue Nov 17, 2015 9:14 am
Location: The Netherlands
Contact:

Re: Update error caused by "No space left on device"

Post by Moem »

moho70 wrote: Sun Feb 18, 2018 6:22 pm I could clean afterwards all old kernels and the updates are installed now.
That's great, now that your topic is solved, please mark it as such. Thanks! :D
Image

If your issue is solved, kindly indicate that by editing the first post in the topic, and adding [SOLVED] to the title. Thanks!
moho70

Re: Update error caused by "No space left on device"

Post by moho70 »

To be honest, I was looking for the "solved" button, but I could't find it, so I wrote, that it is solved :?: :?: ... and I still don't know, how to mark it as solved :oops: :oops:
User avatar
austin.texas
Level 20
Level 20
Posts: 12003
Joined: Tue Nov 17, 2009 3:57 pm
Location: at /home

Re: Update error caused by "No space left on device"

Post by austin.texas »

Go to your first post, click the EDIT (pencil) icon, and add [SOLVED] to the title.
Mint 18.2 Cinnamon, Quad core AMD A8-3870 with Radeon HD Graphics 6550D, 8GB DDR3, Ralink RT2561/RT61 802.11g PCI
Linux Linx 2018
Locked

Return to “Beginner Questions”