📖 ~1 min read
Table of contents
Symptom & Impact
Kernel package configuration fails because initramfs cannot be written to /boot.
Environment & Reproduction
Common on systems with small dedicated /boot partitions.
df -h /boot
sudo apt full-upgrade
sudo update-initramfs -u
Root Cause Analysis
Old kernel images and initrd files consume all available /boot capacity.
Quick Triage
List installed kernels and /boot file sizes.
dpkg -l 'linux-image-*' | awk '/^ii/{print $2}'
ls -lh /boot
df -h /boot
Step-by-Step Diagnosis
Identify stale kernels not matching running version.
uname -r
ls /boot | grep -E 'vmlinuz|initrd'
apt-cache policy linux-image-amd64

Solution – Primary Fix
Purge obsolete kernels, then regenerate initramfs and grub config.
Still having issues? Our Server Management team can diagnose and resolve this for you. Get in touch for a free consultation.
sudo apt autoremove --purge -y
sudo update-initramfs -u -k all
sudo update-grub

Solution – Alternative Approaches
Temporarily move old initrd files off /boot, then clean packages.
sudo mkdir -p /var/tmp/boot-archive
sudo mv /boot/initrd.img-* /var/tmp/boot-archive/
sudo apt -f install -y
Verification & Acceptance Criteria
Kernel package configuration completes and /boot has free space.
df -h /boot
sudo dpkg --audit
sudo update-initramfs -u
Rollback Plan
Restore archived boot files if boot menu entries are missing.
sudo cp -a /var/tmp/boot-archive/* /boot/ 2>/dev/null || true
sudo update-grub
Prevention & Hardening
Run periodic kernel cleanup and monitor /boot utilization.
sudo apt autoremove --purge -y
watch -n 30 df -h /boot
Related Errors & Cross-Refs
Related to dpkg configuration loops and reboot failures after patching.
Related tutorial: View the step-by-step tutorial for Debian 13.
View all Debian 13 tutorials on the Tutorials Hub →
Browse all common problems & solutions on the Tutorials Hub.
References & Further Reading
Debian kernel and initramfs tooling references.
Need Expert Help?
If you cannot resolve this yourself, our team offers hands-on Server Management, Managed IT Services, and flexible Support Plans. Contact us today — we respond within one business day.