Centos8 migrate2rocky.sh fails with Getting system package names for CentOS Linux 8 errors

We have used migrate2rocky.sh to migrate some Centos8 systems to Rocky8 with no problems.
But today we are getting errors like:

“Determining repository names for CentOS Linux 8.Error: Failed to download metadata for repo ‘appstream’: Cannot prepare internal mirrorlist: No URLs in mirrorlist”

This, I guess, is todo with Centos8’s repositories being no longer available or is it some other reason ?
Are there any work arounds ?
Terry

Same problem here - Friday I converted 4 machines; today I get errors
No doubt it’s on the Cent side - I can’t even add a package
Anyone have a work around?

The CentOS Linux 8 repositories have been removed; moved to vault by today.

The part in the script that does access CentOS repos … does it have hardcoded URL’s or does it depend on local repo definitions? If latter, then “fixing” CentOS repo defs to point baseurl to vault could do it.

Thanks

I had to make the change (in my case) to these /etc/yum.repos.d files:
CentOSLinuxAppstream.repo
CentOS-Linux-BaseOS.repo
CentOS-Linux-Extras.repo

commented out the mirrorlist, uncommented the baseurl, and set it to a repo near me (mirror.clarkson.edu)

Updated to Rocky per usual.

#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=AppStream&infra=$infra
baseurl=http://mirror.clarkson.edu/$contentdir/$releasever/AppStream/$basearch/os/

I know you know this stuff, but I figure someone else will come by with the same problem

BTW: Clarkson doesn’t seem to be mirroring Rocky yet :frowning:

Clarkson has now deleted CentOS 8 from their mirror. However, you can use vault.centos.org instead of mirror.clarkson.edu. The CentOS vault should maintain a copy of CentOS 8 indefinitely.

Hi!
Where do I change this? Path? File name?

Regards

I worked fine for me. Thanks!

Change:

CentOSLinuxAppstream.repo
CentOS-Linux-BaseOS.repo
CentOS-Linux-Extras.repo

path: /etc/yum.repos.d

My CentOSLinuxAppstream.repo after I’ve change it:

[appstream]

name=CentOS Linux $releasever - AppStream

#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=AppStream&infra=$infra

#baseurl=http://mirror.centos.org/$contentdir/$releasever/AppStream/$basearch/os/

baseurl=http://vault.centos.org/$contentdir/$releasever/AppStream/$basearch/os/

gpgcheck=1

enabled=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial

This has been fixed in the most recent version of migrate2rocky. Please download a new copy and try again.

Thanks for the fix, but it does not quite work in my case as the “dnf update” fails as shown below I presume due to the missing old repos.
It might be a good to have an option to ignore the “dnf update” ?

Running dnf update before we attempt the migration.
Last metadata expiration check: 0:00:29 ago on Fri Feb 4 08:51:04 2022.
Error:
Problem: cannot install the best update candidate for package kf5-kfilemetadata-5.68.0-1.el8.x86_64

  • nothing provides libpoppler-qt5.so.1()(64bit) needed by kf5-kfilemetadata-5.88.0-1.el8.x86_64
    (try to add ‘–skip-broken’ to skip uninstallable packages or ‘–nobest’ to use not only best candidate packages)

Error running pre-update. Stopping now to avoid putting the system in an
unstable state. Please correct the issues shown here and try again.

An error occurred while we were attempting to convert your system to Rocky Linux. Your system may be unstable. Script will now exit to prevent possible damage.

A log of this installation can be found at /var/log/migrate2rocky.log

Please ignore my message above. This was due to a KDE/PLASMA RPM change. I had to run “dnf config-manager --set-enabled powertools” prior to using the updated migrate2rocky.sh.
After that the Rocky8 migration worked fine.

1 Like

Not having powertools enabled is one of the most common issues I see with Rocky Linux (and other EL8 distributions). It was my goto for this issue before I even checked.

Disabling the initial dnf update would have been a grave mistake. It would have pushed the problem down to the distro-sync leaving you with a half-migrated system that doesn’t work. This is the main reason why we have the dnf update there to begin with, so we can see if it breaks and stop the migration before it does any damage.

I just did a new install (on a vm) but I cannot run a system update also because of connection problem to ‘appstream’. I think the problem is with ‘appstream’ repo site not with local systems

tom kosvic