oracle / centos2ol

Script and documentation to switch CentOS/Rocky Linux to Oracle Linux
https://linux.oracle.com/switch/centos/
Universal Permissive License v1.0
344 stars 81 forks source link

Packages from appstream did not migrate properly to ol8_appstream #142

Closed brianjgrier closed 2 years ago

brianjgrier commented 2 years ago

``While updating a Centos-8 system to Oracle Linux 8 with a running docker container I have encountered an issue where a few packages did not switch from appstream to ol8_appstream .

# yum list installed | grep appstream | grep -v ol8
container-selinux.noarch             2:2.167.0-1.module_el8.5.0+911+f19012f9       @appstream
fuse-overlayfs.x86_64                1.7.1-1.module_el8.5.0+890+6b136101           @appstream
libslirp.x86_64                      4.4.0-1.module_el8.5.0+890+6b136101           @appstream
qemu-guest-agent.x86_64              15:4.2.0-59.module_el8.5.0+1063+c9b9feff.1    @appstream
slirp4netns.x86_64                   1.1.8-1.module_el8.5.0+890+6b136101           @appstream
#

A dnf repoquery on any of these packages results in nothing returned

# dnf repoquery container-selinux.noarch fuse-overlayfs.x86_64 libslirp.x86_64
Last metadata expiration check: 0:05:04 ago on Mon May  9 16:45:10 2022.
#

I was able to verify the packages exist in: https://yum.oracle.com/repo/OracleLinux/OL8/appstream/x86_64/index.html

I can query other packages just not these. There are no excludes defined in the system

# pwd
/etc
# grep -r excludes
lvm/lvm.conf:   # identifies and excludes LVs.
telegraf/telegraf.conf:#   # excludes = [ "/dev/pass6" ]
telegraf/telegraf.conf:#   ## and all found will be included except for the excluded in excludes.
#

This issues does not occur when I migrate a system that does not have docker-ce installed.

The system is running but I will not be able to update these packages in the future.

Without uninstalling docker-ce and it's dependencies prior to updating to OL8, how can I get these packages to be associates with ol8_appstream

totalamateurhour commented 2 years ago

did you use centos2ol.sh to convert this system to Oracle Linux?

brianjgrier commented 2 years ago

For each migration I clone: https://github.com/oracle/centos2ol.git.

totalamateurhour commented 2 years ago

OK, transferred this issue to the appropriate repo.

totalamateurhour commented 2 years ago

The packages you list are part of the container-tools module stream in OL8. You'll probably need to do something like:

dnf module remove <module that currently provides these packages>
dnf module reset <module that currently provides these packages>
dnf module install container-tools
brianjgrier commented 2 years ago

I tried your suggestion and receive this error message:

# dnf module install container-tools
Last metadata expiration check: 1:30:13 ago on Tue May 10 13:02:37 2022.
Installing module 'container-tools:rhel8' from Fail-Safe repository @modulefailsafe is not allowed
No default profiles for module container-tools:rhel8. Available profiles: common
Error: Installing module from Fail-Safe repository is not allowed

All of the modules I listed are in ol8_appstream (x86-64) You can search for them here: https://yum.oracle.com/repo/OracleLinux/OL8/appstream/x86_64/index.html

Also on the systems that I have been testing migration on WITHOUT docker-ce installed I can query those packages:

# dnf repoquery fuse-overlayfs
Last metadata expiration check: 0:54:18 ago on Tue May 10 13:41:32 2022.
fuse-overlayfs-0:0.3-2.module+el8+5201+6423ecab.x86_64
fuse-overlayfs-0:0.3-2.module+el8.0.0+5215+77f672ad.x86_64
fuse-overlayfs-0:0.3-2.module+el8.0.0+5336+de35ffea.x86_64
fuse-overlayfs-0:0.3-2.module+el8.0.0.z+5239+bd2c200f.x86_64
fuse-overlayfs-0:0.4.1-1.module+el8.1.0+5440+994fc847.x86_64
fuse-overlayfs-0:0.7.2-1.module+el8.1.1+5502+fbec5cc6.x86_64
fuse-overlayfs-0:0.7.2-5.module+el8.1.1+5573+1c3f6079.x86_64
fuse-overlayfs-0:0.7.2-5.module+el8.2.0+5584+b2b2d3fb.x86_64
fuse-overlayfs-0:0.7.2-5.module+el8.2.0+7615+180dc822.x86_64
fuse-overlayfs-0:1.0.0-2.module+el8.2.1+7658+86e51d52.x86_64
fuse-overlayfs-0:1.1.2-3.module+el8.3.0+7866+f387f528.x86_64
fuse-overlayfs-0:1.3.0-2.module+el8.3.1+9659+c1901784.x86_64
fuse-overlayfs-0:1.4.0-2.module+el8.4.0+20157+b6591bfb.x86_64
fuse-overlayfs-0:1.4.0-3.module+el8.4.0+20195+0a4a4953.x86_64
fuse-overlayfs-0:1.6-1.module+el8.4.0+20289+730b73cc.x86_64
fuse-overlayfs-0:1.7.1-1.module+el8.5.0+20416+d687fed7.x86_64
fuse-overlayfs-0:1.8-1.module+el8.5.0+20494+0311868c.x86_64
totalamateurhour commented 2 years ago

Can you disable this repository? Fail-Safe repository @modulefailsafe

brianjgrier commented 2 years ago

No, there is no repository with that name:

# pwd
/etc/yum.repos.d
# grep fail *repo
#
totalamateurhour commented 2 years ago

what's the output of:

dnf module list --installed
dnf module list --enabled
dnf repolist
brianjgrier commented 2 years ago
# dnf repolist
repo id                                                                          repo name
docker-ce-stable                                                                 Docker CE Stable - x86_64
ol8_appstream                                                                    Oracle Linux 8 Application Stream (x86_64)
ol8_baseos_latest                                                                Oracle Linux 8 BaseOS Latest (x86_64)
ol8_developer_EPEL                                                               Oracle Linux 8 EPEL Packages for Development (x86_64)
ol8_developer_EPEL_modular                                                       Oracle Linux 8 EPEL Modular Packages for Development (x86_64)
# dnf module list --installed
Last metadata expiration check: 3:32:07 ago on Wed May 11 07:56:03 2022.
# dnf module list --enabled
Last metadata expiration check: 3:32:33 ago on Wed May 11 07:56:03 2022.
@modulefailsafe
Name               Stream        Profiles Summary
container-tools    rhel8 [e]     common   Most recent (rolling) versions of podman, buildah, skopeo, runc, conmon, runc, conmon, CRIU, Udica, etc as well as dependencies such as container-selinux b
                                          uilt and tested together, and updated as frequently as every 12 weeks.
virt               rhel [e]      common   Virtualization module

Oracle Linux 8 Application Stream (x86_64)
Name               Stream        Profiles Summary
idm                client [d][e] common [ OL IdM long term support client module
                                 d]
mariadb            10.3 [d][e]   client,  MariaDB Module
                                 galera,
                                 server [
                                 d]
perl               5.26 [d][e]   common [ Practical Extraction and Report Language
                                 d], mini
                                 mal
perl-IO-Socket-SSL 2.066 [d][e]  common [ Perl library for transparent TLS
                                 d]
perl-libwww-perl   6.34 [d][e]   common [ A Perl interface to the World-Wide Web
                                 d]
python36           3.6 [d][e]    build, c Python programming language, version 3.6
                                 ommon [d
                                 ]
redis              5 [d][e]      common [ Redis persistent key-value database
                                 d]
satellite-5-client 1.0 [d][e]    common [ ULN client packages
                                 d], gui

Hint: [d]efault, [e]nabled, [x]disabled, [i]nstalled

So it appears that @modulefailsafe is there. I just do not know how to disable it

Going to try a reposync

totalamateurhour commented 2 years ago

It's an artifact of module metadata not being available

https://dnf.readthedocs.io/en/latest/modularity.html#repositories-with-module-metadata-are-unavailable

Now we need to figure out how you got to this state.

brianjgrier commented 2 years ago

The install command is/was: centos2ol.sh -k

I can restore the system to the pre-update snapshot and collect any information you want.

totalamateurhour commented 2 years ago

I'd like @Djelibeybi's input on this.

Djelibeybi commented 2 years ago

This is one of the reasons we document the requirement to remove non-base RPMs prior to migration. The simplest fix is to rollback, remove docker-ce (and its dependencies) before migration and then run the script.

brianjgrier commented 2 years ago

Removing all the software off a system to switch to your OS, then re-deploy any software above the OS does not make any sense. At that point it would be less work to just spin up a new VM on OL7/8 and redeploy the applications.

I will report back to my management and let them decide if they want to move ahead with Oracle Linux.

Djelibeybi commented 2 years ago

The problem is that we can't control the dependencies that are pulled in by non-base packages. This is particularly problematic with CentOS because their versioning deviated from RHEL's standard.

This is a problem for all migration tools. The AlmaLinux Elevate package has a similar restriction: https://wiki.almalinux.org/elevate/ELevate-frequent-issues.html#known-issues

brianjgrier commented 2 years ago

I understand, but I would make it much more clear that you cannot support Centos to Oracle migrations with anything but a base system. I would suggest adding the text of your last reply to the README file for people looking to migrate.

My management was hoping to avoid Centos Stream, which has migration issues also. We will have to look at a rolling replacement strategy if they want to migrate to Oracle Linux.

brianjgrier commented 2 years ago

There is no need to continue this issue.

Thanks for the explaniation

Djelibeybi commented 2 years ago

You'll need a rolling replacement strategy to move to any other drop-in replacement distro, not just Oracle Linux, because they have the same constraints that we do.