/boot is 100% full on RHEL 8 when using XFS

I’m pretty knowledgeable with Linux, yet I don’t know what to do, but rebuild the system.
Can you help?
On RHEL 8.4 system
System disk is 119 GB
/boot filesystem reside on 1GB disk partition.
/boot filesystem is xfs.
Counting files sum up with about 190 MB only.

What is the possible cause?
How to fix the situation?

What does df and du says?

df -TH /boot
du -ch /boot

Can you remove older kernel? Something like:

sudo dnf list --installed kernel

Then remove older kernel

sudo dnf remove --oldinstallonly
# keep 2 number of kernels should be retained
sudo dnf remove --oldinstallonly --setopt installonly_limit=2 kernel

[root@redwood ~]# du -ch /boot
0 /boot/efi/EFI/redhat
0 /boot/efi/EFI
0 /boot/efi
3.1M /boot/grub2/i386-pc
2.5M /boot/grub2/fonts
5.5M /boot/grub2
1.1M /boot/extlinux
16K /boot/loader/entries
16K /boot/loader
185M /boot
185M total
[root@redwood ~]# df -TH /boot
Filesystem Type Size Used Avail Use% Mounted on
/dev/sdb1 xfs 1.1G 1.1G 0 100% /boot

I manually removed the large files of 4.18.0-305.el8 from /boot. My intention was to keep the original installation and the last one.

[root@redwood ~]# dnf list --installed kernel
Updating Subscription Management repositories.
Installed Packages
kernel.x86_64 4.18.0-240.el8 @anaconda
kernel.x86_64 4.18.0-305.el8 @rhel-8-for-x86_64-baseos-rpms
kernel.x86_64 4.18.0-305.7.1.el8_4 @rhel-8-for-x86_64-baseos-rpms

Run xfs_estimate on /boot and see what it says. My best guess now is some sort of xfs issue. You need to look into xfs_check and then mostly xfs_repair to fix the issue. Run all commands in single user mode.

Thank you, your advise helped. The problem was that it has to be done in single user mode. That solved the issue.

Avigdor


Linux sysadmin blog - Linux/Unix Howtos and Tutorials - Linux bash shell scripting wiki