Remove unnecessary boot items from centos
After CentOS is updated, the old kernel is not automatically deleted. Therefore, there are multiple kernel options in the startup options. You can manually use the following command to delete unnecessary kernels:
1. view the current kernel version of the system:
# Uname-
Linux localhost. localdomain 3.10.0-229.20.1.el7.x86 _ 64 #1 SMP Tue Nov 3 19:10:07 UTC 201GNU/Linux
2. View All kernel RPM packages in the system:
# Rpm-qa | grep kernel
Kernel-3.10.0-229.14.1.el7.x86_64
Kernel-3.10.0-229.el7.x86_64
Abrt-addon-kerneloops-2.1.11-22.el7.centos.0.1.x86_64
Kernel-tools-libs-3.10.0-229.20.1.el7.x86_64
Kernel-3.10.0-229.20.1.el7.x86_64
Kernel-tools-3.10.0-229.20.1.el7.x86_64
3. Delete the RPM package of the old Kernel
Yum removekernel-3.10.0-229.14.1.el7
Yum remove kernel-3.10.0-229.el7
4. restart the system
# Reboot
Note: you do not need to manually modify/boot/grub/menu. lst.