早上,虚拟机上的 CentOS7 重启系统升级过程中,手抖把升级进程给中止了。

导致系统无法重启。

image

重置是不可以重置了。

在网上搜索了一下解决方案,大部分文章的说法都不可行。按这个文章 的说法,换了个内核进行启动。

image

然后,删除有问题的内核 kernel-3.10.0-957.1.3.el7.x86_64,再重启,问题就解决了。

~ rpm -qa|grep kernel
abrt-addon-kerneloops-2.1.11-52.el7.centos.x86_64
kernel-tools-3.10.0-957.1.3.el7.x86_64
kernel-3.10.0-862.14.4.el7.x86_64
kernel-headers-3.10.0-957.1.3.el7.x86_64
kernel-tools-libs-3.10.0-957.1.3.el7.x86_64
kernel-devel-3.10.0-862.14.4.el7.x86_64
kernel-3.10.0-957.1.3.el7.x86_64
kernel-3.10.0-693.el7.x86_64
kernel-devel-3.10.0-957.1.3.el7.x86_64
➜  ~ sudo yum remove kernel-3.10.0-957.1.3.el7.x86_64
[sudo] password for deloz: 
Loaded plugins: fastestmirror, langpacks
Resolving Dependencies
There are unfinished transactions remaining. You might consider running yum-complete-transaction, or "yum-complete-transaction --cleanup-only" and "yum history redo last", first to finish them. If those don't work you'll have to try removing/installing packages by hand (maybe package-cleanup can help).
--> Running transaction check
---> Package kernel.x86_64 0:3.10.0-957.1.3.el7 will be erased
--> Finished Dependency Resolution

Dependencies Resolved

===================================================================================================================================================================================================================
 Package                                        Arch                                           Version                                                     Repository                                         Size
===================================================================================================================================================================================================================
Removing:
 kernel                                         x86_64                                         3.10.0-957.1.3.el7                                          installed                                          63 M

Transaction Summary
===================================================================================================================================================================================================================
Remove  1 Package

Installed size: 63 M
Is this ok [y/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Erasing    : kernel-3.10.0-957.1.3.el7.x86_64                                                                                                                                                                1/1 
  Verifying  : kernel-3.10.0-957.1.3.el7.x86_64                                                                                                                                                                1/1 

Removed:
  kernel.x86_64 0:3.10.0-957.1.3.el7                                                                                                                                                                               

Complete!

0 comments