(SOLVED) - Low Disk Space on "boot" error

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
User avatar
felemur
Level 5
Level 5
Posts: 537
Joined: Sun Sep 20, 2015 2:22 pm
Location: In the middle of 1000's of acres of corn & soy fields in a house full of cats.

(SOLVED) - Low Disk Space on "boot" error

Post by felemur »

When I'm doing updates, I get a Low Disk Space on "Boot" popup.

I checked my SSD, and I've got loads of free space.

Not sure what this is about or what to do.

Screenshot from 2018-11-19 14-32-14.png
Screenshot from 2018-11-19 14-32-55.png
Screenshot from 2018-11-19 14-33-26.png

Mint 19 Cinnamon, Dell Optiplex 7010 with SSD
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 3 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
WharfRat

Re: Low Disk Space on "boot" error

Post by WharfRat »

It's the boot partition that's running out of space.
User avatar
felemur
Level 5
Level 5
Posts: 537
Joined: Sun Sep 20, 2015 2:22 pm
Location: In the middle of 1000's of acres of corn & soy fields in a house full of cats.

Re: Low Disk Space on "boot" error

Post by felemur »

OK makes sense from the message, but what do I do? BTW, why doesn't it just take more space from the open space in the SSD?
gm10

Re: Low Disk Space on "boot" error

Post by gm10 »

Remove old kernels either via Update Manager or all in one go by running this in a terminal window:

Code: Select all

dpkg-query -W -f '${Version}\n' 'linux-image-[^g]*'|sort -u|sed -e '/^$/d' -e 's/\~[^~]*$//' -e 's/\.[^.]*$//' -e "/$(uname -r|sed 's/-generic\|-lowlatency//')/d" -e 's/.*/linux-*-&*/'|tr '\n' ' '|xargs -pr sudo apt-get remove --purge -y
If the script fails due to lack of free space see here: viewtopic.php?p=1536906#p1536906
felemur wrote: Mon Nov 19, 2018 4:56 pm BTW, why doesn't it just take more space from the open space in the SSD?
Due to the way your drive is partitioned it cannot do that, it's limited to the space allocated to /boot.
WharfRat

Re: Low Disk Space on "boot" error

Post by WharfRat »

You probably never cleaned the older kernels after kernel updtaes.

Make sure you're booted to the latest then and copy and paste the following in one fell swoop into the terminal

Code: Select all

OLDCONF=$(dpkg -l|grep "^rc"|awk '{print $2}')
CURKERNEL=$(uname -r|sed 's/-*[a-z]//g'|sed 's/-386//g')
LINUXPKG="linux-(image|headers|modules|ubuntu-modules|restricted-modules)"
METALINUXPKG="linux-(image|headers|restricted-modules)-(generic|i386|server|common|rt|xen)"
OLDKERNELS=$(dpkg -l|awk '{print $2}'|grep -E $LINUXPKG |grep -vE $METALINUXPKG|grep -v $CURKERNEL)
sudo apt-get purge $OLDKERNELS
It will prompt to continue or not.
User avatar
felemur
Level 5
Level 5
Posts: 537
Joined: Sun Sep 20, 2015 2:22 pm
Location: In the middle of 1000's of acres of corn & soy fields in a house full of cats.

Re: Low Disk Space on "boot" error

Post by felemur »

gm10 wrote: Mon Nov 19, 2018 4:59 pm Remove old kernels either via Update Manager or all in one go by running this in a terminal window:

Code: Select all

dpkg-query -W -f '${Version}\n' 'linux-image-[^g]*'|sort -u|sed -e '/^$/d' -e 's/\~[^~]*$//' -e 's/\.[^.]*$//' -e "/$(uname -r|sed 's/-generic\|-lowlatency//')/d" -e 's/.*/linux-*-&*/'|tr '\n' ' '|xargs -pr sudo apt-get remove --purge -y
If the script fails due to lack of free space see here: viewtopic.php?p=1536906#p1536906
felemur wrote: Mon Nov 19, 2018 4:56 pm BTW, why doesn't it just take more space from the open space in the SSD?
Due to the way your drive is partitioned it cannot do that, it's limited to the space allocated to /boot.

Thank You, that seems to have worked as it removed a fair bit. Appreciate the help.

I don't remember choosing how much space to allocate for that, but maybe I did. Thought I just did a standard fresh install when Mint 19 came out, but I'm a user who is so-so technically.
User avatar
felemur
Level 5
Level 5
Posts: 537
Joined: Sun Sep 20, 2015 2:22 pm
Location: In the middle of 1000's of acres of corn & soy fields in a house full of cats.

Re: Low Disk Space on "boot" error

Post by felemur »

WharfRat wrote: Mon Nov 19, 2018 5:03 pm You probably never cleaned the older kernels after kernel updtaes.

Make sure you're booted to the latest then and copy and paste the following in one fell swoop into the terminal

Code: Select all

OLDCONF=$(dpkg -l|grep "^rc"|awk '{print $2}')
CURKERNEL=$(uname -r|sed 's/-*[a-z]//g'|sed 's/-386//g')
LINUXPKG="linux-(image|headers|modules|ubuntu-modules|restricted-modules)"
METALINUXPKG="linux-(image|headers|restricted-modules)-(generic|i386|server|common|rt|xen)"
OLDKERNELS=$(dpkg -l|awk '{print $2}'|grep -E $LINUXPKG |grep -vE $METALINUXPKG|grep -v $CURKERNEL)
sudo apt-get purge $OLDKERNELS
It will prompt to continue or not.
Thanks, but by the time I saw your post, I had already run the code posted by gm10.

Appreciate the help from both of you.
WharfRat

Re: Low Disk Space on "boot" error

Post by WharfRat »

If you opted for LVM or encrypted it doesn't ask how large of a boot partition to allocate :wink:
User avatar
felemur
Level 5
Level 5
Posts: 537
Joined: Sun Sep 20, 2015 2:22 pm
Location: In the middle of 1000's of acres of corn & soy fields in a house full of cats.

Re: Low Disk Space on "boot" error

Post by felemur »

WharfRat wrote: Mon Nov 19, 2018 5:07 pm If you opted for LVM or encrypted it doesn't ask how large of a boot partition to allocate :wink:
Ah, OK. This is the first time I did an encrypted install. I've been using Mint since 17.2, but none before were encrypted.

I'm learning - slowly, but learning.
Locked

Return to “Installation & Boot”