rocky-tools icon indicating copy to clipboard operation
rocky-tools copied to clipboard

migrate2rocky.sh aborts "Failed to download metadata for repo 'PowerTools'"

Open m1schmidt opened this issue 3 years ago • 10 comments

The migration was running along fine -- is there a way to recover gracefully?

migrate2rocky.log

m1schmidt avatar Feb 09 '22 21:02 m1schmidt

Thanks for the report.

Can you show me the current output of dnf repolist all; dnf repoinfo PowerTools powertools

Thanks

pajamian avatar Feb 09 '22 22:02 pajamian

dnf repolist all

repo id repo name status PowerTools CentOS-8 - PowerTools enabled appstream Rocky Linux 8 - AppStream enabled appstream-debug Rocky Linux 8 - AppStream - Source disabled appstream-source Rocky Linux 8 - AppStream - Source disabled baseos Rocky Linux 8 - BaseOS enabled baseos-debug Rocky Linux 8 - BaseOS - Source disabled baseos-source Rocky Linux 8 - BaseOS - Source disabled devel Rocky Linux 8 - Devel WARNING! FOR BUILDROOT AND KOJI USE enabled elrepo ELRepo.org Community Enterprise Linux Repository - el8 enabled elrepo-extras ELRepo.org Community Enterprise Linux Extras Repository - el8 disabled elrepo-kernel ELRepo.org Community Enterprise Linux Kernel Repository - el8 disabled elrepo-testing ELRepo.org Community Enterprise Linux Testing Repository - el8 disabled epel Extra Packages for Enterprise Linux 8 - x86_64 enabled epel-debuginfo Extra Packages for Enterprise Linux 8 - x86_64 - Debug disabled epel-modular Extra Packages for Enterprise Linux Modular 8 - x86_64 enabled epel-modular-debuginfo Extra Packages for Enterprise Linux Modular 8 - x86_64 - Debug disabled epel-modular-source Extra Packages for Enterprise Linux Modular 8 - x86_64 - Source disabled epel-source Extra Packages for Enterprise Linux 8 - x86_64 - Source disabled epel-testing Extra Packages for Enterprise Linux 8 - Testing - x86_64 disabled epel-testing-debuginfo Extra Packages for Enterprise Linux 8 - Testing - x86_64 - Debug disabled epel-testing-modular Extra Packages for Enterprise Linux Modular 8 - Testing - x86_64 disabled epel-testing-modular-debuginfo Extra Packages for Enterprise Linux Modular 8 - Testing - x86_64 - Debug disabled epel-testing-modular-source Extra Packages for Enterprise Linux Modular 8 - Testing - x86_64 - Source disabled epel-testing-source Extra Packages for Enterprise Linux 8 - Testing - x86_64 - Source disabled extras Rocky Linux 8 - Extras enabled ha Rocky Linux 8 - HighAvailability disabled ha-debug Rocky Linux 8 - High Availability - Source disabled ha-source Rocky Linux 8 - High Availability - Source disabled media-appstream Rocky Linux 8 - Media - AppStream disabled media-baseos Rocky Linux 8 - Media - BaseOS disabled nfv Rocky Linux 8 - NFV disabled plus Rocky Linux 8 - Plus disabled powertools Rocky Linux 8 - PowerTools enabled powertools-debug Rocky Linux 8 - PowerTools - Source disabled powertools-source Rocky Linux 8 - PowerTools - Source disabled resilient-storage Rocky Linux 8 - ResilientStorage disabled resilient-storage-debug Rocky Linux 8 - Resilient Storage - Source disabled resilient-storage-source Rocky Linux 8 - Resilient Storage - Source disabled rt Rocky Linux 8 - Realtime disabled zfs ZFS on Linux for EL8 - dkms enabled zfs-kmod ZFS on Linux for EL8 - kmod disabled zfs-source ZFS on Linux for EL8 - Source disabled zfs-testing ZFS on Linux for EL8 - dkms - Testing disabled zfs-testing-kmod ZFS on Linux for EL8 - kmod - Testing disabled zfs-testing-source ZFS on Linux for EL8 - Testing Source disabled

dnf repoinfo PowerTools powertools

CentOS-8 - PowerTools 595 B/s | 38 B 00:00
Error: Failed to download metadata for repo 'PowerTools': Cannot prepare internal mirrorlist: No URLs in mirrorlist

m1schmidt avatar Feb 10 '22 12:02 m1schmidt

What's the output of: grep PowerTools /etc/yum.repos.d/*.repo

pajamian avatar Feb 11 '22 00:02 pajamian

I should note that you still have PowerTools installed from CentOS somehow. RockyLinux powertools is also installed. The initial system package swap successfully removed centos-linux-repos which should have removed the PowerTools repo from CentOS, so there appears to be an errant .repo file in your yum.repos.d directory that is still trying to reference PowerTools and the goal here is to find out what it is and why it's there.

pajamian avatar Feb 11 '22 00:02 pajamian

grep PowerTools /etc/yum.repos.d/*.repo

/etc/yum.repos.d/CentOS-PowerTools.repo:# CentOS-PowerTools.repo /etc/yum.repos.d/CentOS-PowerTools.repo:[PowerTools] /etc/yum.repos.d/CentOS-PowerTools.repo:name=CentOS-$releasever - PowerTools /etc/yum.repos.d/CentOS-PowerTools.repo:mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=PowerTools&infra=$infra /etc/yum.repos.d/CentOS-PowerTools.repo:#baseurl=http://mirror.centos.org/$contentdir/$releasever/PowerTools/$basearch/os/ /etc/yum.repos.d/Rocky-Debuginfo.repo:name=Rocky Linux $releasever - PowerTools - Source /etc/yum.repos.d/Rocky-Debuginfo.repo:mirrorlist=https://mirrors.rockylinux.org/mirrorlist?arch=$basearch&repo=PowerTools-$releasever-debug /etc/yum.repos.d/Rocky-Debuginfo.repo:#baseurl=http://dl.rockylinux.org/$contentdir/$releasever/PowerTools/$basearch/debug/tree/ /etc/yum.repos.d/Rocky-PowerTools.repo:# Rocky-PowerTools.repo /etc/yum.repos.d/Rocky-PowerTools.repo:name=Rocky Linux $releasever - PowerTools /etc/yum.repos.d/Rocky-PowerTools.repo:mirrorlist=https://mirrors.rockylinux.org/mirrorlist?arch=$basearch&repo=PowerTools-$releasever /etc/yum.repos.d/Rocky-PowerTools.repo:#baseurl=http://dl.rockylinux.org/$contentdir/$releasever/PowerTools/$basearch/os/ /etc/yum.repos.d/Rocky-Sources.repo:name=Rocky Linux $releasever - PowerTools - Source /etc/yum.repos.d/Rocky-Sources.repo:mirrorlist=https://mirrors.rockylinux.org/mirrorlist?arch=source&repo=PowerTools-$releasever-source /etc/yum.repos.d/Rocky-Sources.repo:#baseurl=http://dl.rockylinux.org/$contentdir/$releasever/PowerTools/source/tree/

m1schmidt avatar Feb 11 '22 01:02 m1schmidt

I'm fine with removing the CentOS PowerTools repo. Is it possible to continue along with the migration at this point?

m1schmidt avatar Feb 11 '22 01:02 m1schmidt

You would have to finish it manually. My recommendation is to start over if you can and:

mv /etc/yum.repos.d/CentOS-PowerTools.repo{,.DISABLED}
migrate2rocky -r
dnf config-manager --set-enabled powertools

pajamian avatar Feb 11 '22 04:02 pajamian

I will likely start over, however I was thinking about running the migration manually. I've looked through the documentation and don't see a procedure outlined for a manual finish. Can you point me in the right direction?

m1schmidt avatar Feb 11 '22 08:02 m1schmidt

Just a dnf distro-sync followed by fixing up EFI boot if applicable.

pajamian avatar Feb 11 '22 18:02 pajamian

i got fail migration centos 8 already upgraded to 8.5.2111 before running the script for migration, fail just before converting packages, with error messages of fail to get metadata 'Base OS' or Appstream.

I already try solution from @pajamian that seem work to other user, but still no luck. Try other approach as well as discussed in rocky linux forum. Still failing.

One thing that i did may relate is may be this command that i entered when installing postgresql-12 like this sudo dnf -q -y module disable postgresql dnf update is ok and uptodate before migration script started.

Is anything i miss for successful migration, please help.

bunhin avatar Mar 01 '22 23:03 bunhin