[root@localhost ~]# yum remove kernel-tools-libs-3.10.0-1160.95.1.el7.x86_64
Loaded plugins: fastestmirror
Resolving Dependencies
--> Running transaction check
---> Package kernel-tools-libs.x86_64 0:3.10.0-1160.95.1.el7 will be erased
--> Processing Dependency: kernel-tools-libs = 3.10.0-1160.95.1.el7 for package: kernel-tools-3.10.0-1160.95.1.el7.x86_64
--> Processing Dependency: libcpupower.so.0()(64bit) for package: kernel-tools-3.10.0-1160.95.1.el7.x86_64
--> Running transaction check
---> Package kernel-tools.x86_64 0:3.10.0-1160.95.1.el7 will be erased
--> Finished Dependency Resolution
Dependencies Resolved
========================================================================================================================
Package Arch Version Repository Size
========================================================================================================================
Removing:
kernel-tools-libs x86_64 3.10.0-1160.95.1.el7 @updates 18 k
Removing for dependencies:
kernel-tools x86_64 3.10.0-1160.95.1.el7 @updates 337 k
Transaction Summary
========================================================================================================================
Remove 1 Package (+1 Dependent package)
Installed size: 355 k
Is this ok [y/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Erasing : kernel-tools-3.10.0-1160.95.1.el7.x86_64 1/2
Erasing : kernel-tools-libs-3.10.0-1160.95.1.el7.x86_64 2/2
Verifying : kernel-tools-libs-3.10.0-1160.95.1.el7.x86_64 1/2
Verifying : kernel-tools-3.10.0-1160.95.1.el7.x86_64 2/2
Removed:
kernel-tools-libs.x86_64 0:3.10.0-1160.95.1.el7
Dependency Removed:
kernel-tools.x86_64 0:3.10.0-1160.95.1.el7
Complete!
使用 `grub2-mkconfig -o /boot/grub2/grub.cfg` 更新引导配置
[root@localhost ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-6.5.2
Found initrd image: /boot/initramfs-6.5.2.img
Found linux image: /boot/vmlinuz-0-rescue-0197527dc1e0e34ab25e04d6402a7388
Found initrd image: /boot/initramfs-0-rescue-0197527dc1e0e34ab25e04d6402a7388.img
done