centos yum updates and removes excess startup entries
- 2020-08-22 23:21:15
- OfStack
There are several ways to update, this time with the yum installation in the presence of a network
The command line is simple
yum update
And then y,
If you restart after the update, you will find a few more boot items, so how can you remove these redundant kernels? Or an old unused kernel?
1, view the current running kernel version
uname -a
2. Check all kernel in the system
rpm -q kernel
3. delete old kernel
[
yum remove kernel-3.XXXXX.el7
yum remove ES39en-ES40en... . el7
These deletions are redundant kernels
4, reboot:
reboot
Found that the redundant kernel boot has been removed
Detailed steps for other partners are attached
[
1. View the current kernel version of the system:
# uname -a
Linux localhost.localdomain 3.10.0-229.20.1.el7.x86_64 #1 SMP Tue Nov 3 19:10:07 UTC 201
GNU/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 for the old kernel
yum remove kernel-3.10.0-229.14.1.el7
yum remove kernel-3.10.0-229.el7
Restart the system
# reboot
Note: do not need to manually modify/boot grub/menu lst