CentOS 7 - Remove Old Kernels
/boot partition is getting filled, you may wish to automatically remove old kernels. I find the best way to do this is to install the yum utilities package and then use a command to delete all but 2 kernels (just in case there is a problem with the latest one).
sudo yum install yum-utils -y sudo package-cleanup --oldkernels --count=2
First published: 16th August 2018