/boot partition is full – Ubuntu – CentOs

/boot partition is full – Ubuntu – CentOs

#Check the current kernel version

uname -a

See the list of installed kernels

rpm -qa | grep kernel

 

Ubuntu
CentOS:

apt autoremove --purge

 

#remove all old kernels – keep the lastest 2

package-cleanup --oldkernels --count=2