How to fix E: /boot has insufficient space for new kernel in APT

APTINTERMEDIATEHIGHUpdated Dec 29, 2025· 177 views

The /boot partition is full and cannot install new kernel updates. This occurs when old kernel versions accumulate and consume all available space. Free up space by removing old unused kernels.

Quick fix

Fixes E: /boot has insufficient space for new kernel

df -h /boot
  1. Verify /boot partition is full
  2. Identify your current running kernel
  3. List all installed kernels
  4. Remove old kernel packages
apt — error
df -h /boot
E: /boot has insufficient space for new kernel

What this error means

This error occurs when your /boot partition (which stores kernel images, initramfs files, and bootloader data) has reached 100% capacity. Most Linux systems allocate a separate /boot partition with limited space—typically only enough for 3-5 kernel versions. When kernel updates accumulate without old versions being removed, the partition fills up and prevents new kernel installations. This is a common issue on systems that haven't been maintained or have automatic updates enabled without cleanup policies.

Typical symptoms

  • Kernel updates fail with 'insufficient space' error
  • apt upgrade command cannot complete
  • /boot partition shows 100% usage with 'df -h /boot'
  • System boots normally but cannot install security updates
  • apt autoremove command has no effect (partition already full)

Common causes

  1. Multiple old kernel versions stored in /boot directory (most common)
  2. initramfs files from previous kernels consuming space
  3. Kernel images not automatically cleaned up after updates
  4. /boot partition sized too small for the expected kernel count
  5. Compressed initramfs not enabled (larger initrd.img files)

How to fix "E: /boot has insufficient space for new kernel"

1Verify /boot partition is full

Check the current space usage of the /boot partition:

bash
df -h /boot

If the 'Use%' column shows 100%, the partition is indeed full.

2Identify your current running kernel

Find the kernel version you are currently running (do not remove this one):

bash
uname -r

Example output: 5.15.0-91-generic. This is the kernel you must keep.

3List all installed kernels

View all installed kernel packages:

bash
dpkg -l | grep linux-image

This shows all kernel versions. Identify old ones (lower version numbers) that differ from your current running kernel.

4Remove old kernel packages

Remove old kernel packages one at a time. Replace VERSION-NUMBER with the kernel version you want to remove:

bash
sudo apt remove --purge linux-image-VERSION-NUMBER-generic
sudo apt remove --purge linux-image-unsigned-VERSION-NUMBER-generic

Example:

bash
sudo apt remove --purge linux-image-5.13.0-44-generic
sudo apt remove --purge linux-image-unsigned-5.13.0-44-generic

Remove the 2-3 oldest kernels, keeping at least one older kernel as a backup in case the current kernel has issues.

5Clean up remaining packages

After removing old kernels, run autoremove to clean up related dependencies:

bash
sudo apt autoremove --purge

Then update the bootloader configuration:

bash
sudo update-grub
6Verify space was freed

Confirm that /boot partition now has free space:

bash
df -h /boot

You should see the 'Use%' below 80%. You can now proceed with kernel updates.

7If apt is completely broken (100% full)

If the partition is so full that apt cannot run, use dpkg directly:

bash
sudo dpkg --configure -a
sudo dpkg --purge $(dpkg -l | grep linux-image | awk '{print $2}' | grep -v $(uname -r | sed 's/-[a-z]*$//'))
sudo apt-get -f install

This forcefully removes old kernel packages without relying on apt's dependency resolution.

Advanced notes

Prevention: To prevent this issue, keep only 2-3 recent kernels. Add to /etc/apt/apt.conf.d/50unattended-upgrades (if using unattended-upgrades):

bash
Unattended-Upgrade::Remove-Unused-Kernel-Packages "true";
Unattended-Upgrade::Remove-Unused-Dependencies "true";

Alternatively, reduce initramfs compression overhead by enabling xz compression in /etc/initramfs-tools/initramfs.conf:

bash
COMPRESS=xz

Then rebuild:

bash
sudo update-initramfs -u -k all

Long-term: If /boot is frequently full, consider resizing the partition to 1GB using gparted or similar tools. Most modern systems should have 500MB-1GB for /boot to safely hold 4-5 kernel versions.

Frequently asked questions

What does "E: /boot has insufficient space for new kernel" mean?
This error occurs when your /boot partition (which stores kernel images, initramfs files, and bootloader data) has reached 100% capacity. Most Linux systems allocate a separate /boot partition with limited space—typically only enough for 3-5 kernel versions. When kernel updates accumulate without old versions being removed, the partition fills up and prevents new kernel installations.
How do I fix "E: /boot has insufficient space for new kernel"?
The /boot partition is full and cannot install new kernel updates. This occurs when old kernel versions accumulate and consume all available space. Free up space by removing old unused kernels.
What causes "E: /boot has insufficient space for new kernel"?
Multiple old kernel versions stored in /boot directory (most common) initramfs files from previous kernels consuming space Kernel images not automatically cleaned up after updates
Is the "E: /boot has insufficient space for new kernel" error serious?
Yes. This is a high-severity error that usually blocks work until it is fixed, but the steps above resolve it.

Official resources & further reading