Problem during upgrading centos version

General support questions
Post Reply
bischop
Posts: 6
Joined: 2021/12/22 22:19:41

Problem during upgrading centos version

Post by bischop » 2022/01/13 19:25:08

When trying to upgrade Centos 7 -> 8 I got an error. How to fix it?

Code: Select all

root@cerebro ~# dnf clean all
71 files removed
⏎
root@cerebro ~# rpm -e `rpm -q kernel`
package `rpm is not installed
package kernel` is not installed                                                                                           

root@cerebro ~# rpm -e --nodeps sysvinit-tools
⏎                                                                                               

root@cerebro ~# dnf -y --releasever=8 --allowerasing --setopt=deltarpm=false distro-sync
Extra Packages for Enterprise Linux 8 - x86_64                    16 MB/s |  11 MB     00:00
CentOS Linux 8 - BaseOS                                          6.0 MB/s | 4.6 MB     00:00
ELRepo.org Community Enterprise Linux Repository - el7           167 kB/s | 296 kB     00:01
Nux.Ro RPMs for general desktop use                              2.6 MB/s | 4.2 MB     00:01
Extra Packages for Enterprise Linux Modular 8 - x86_64           1.3 MB/s | 979 kB     00:00
Copr repo for snapcore-el7 owned by ngompa                        46 kB/s |  27 kB     00:00
CentOS Linux 8 - AppStream                                       1.9 MB/s | 8.4 MB     00:04
CentOS Linux 8 - Extras                                          238 kB/s |  10 kB     00:00
Error:
 Problem: The operation would result in removing the following protected packages: kernel

Whoever
Posts: 1357
Joined: 2013/09/06 03:12:10

Re: Problem during upgrading centos version

Post by Whoever » 2022/01/13 21:37:39

How to fix it?

Don't try.

1. CentOS 8 has already passed EOL and is no longer supported, so you would be moving from a supported OS version to an unsupported OS version.
2. There never was a supported way to upgrade in place from CentOS 7 to 8.

User avatar
jlehtone
Posts: 4523
Joined: 2007/12/11 08:17:33
Location: Finland

Re: Problem during upgrading centos version

Post by jlehtone » 2022/01/13 22:02:12

Indeed. The only supported method is to install a new OS from scratch. User data you will probably transfer by some means.


That said, if you really have nothing to lose with your current install (have valid backups, etc), then you could give ELevate a shot. https://almalinux.org/elevate
(It can't migrate every possible setup, but of all unsupported procedures it looks least scary.)

Post Reply