CentOS8 to AlmaLinux8 Migration Error

I have a CentOS 8.5 server that I wish to migrate but it is in an air gapped network (no internet connection). It has been patched to the latest 8.5 updates but I only see the migration script to get everything online. I used rsync with a mirror to download everything AlmaLinux8 and Elevate on an external USB drive and I created all my repos pointing to before mentioned updates.

I used the “ELevate Offline Guide” to a point…

  • The dnf update with my previous CentOS8 repos updated my system
  • After I disabled this repo and put the AlmaLinux8 and ELevate repo i did a “dnf update” and it did in fact update again all of my el8 packages
  • The “dnf install -y leapp-upgrade leapp-data-almalinux” worked
  • The leapp preupgrade did ran and at first gave me a target_user error so I rebooted
  • Repeated the leapp-preupgrade and it runs but now the error is “scan_source_kernel”

What am I missing? I cannot deploy the almalinux.sh and I’m pretty sure I downloaded all AppStream, BaseOS, extras and plus repos to my external drive. Do I need another repo besides the ones I mentioned?

leapp–report

Risk Factor: high (error)
Title: Unable to identify package providing the booted kernel.
Summary:
Key: 46f76f6124b5537e5dfd0e6c250d3f42c8a97691

Risk Factor: high
Title: Packages from unknown repositories may not be installed
Summary: 1 packages may not be installed or upgraded due to repositories unknown to leapp:

  • python3-systemd (repoid: almalinux8-baseos)
    Remediation: [hint] In case the listed repositories are mirrors of official repositories for RHEL (provided by Red Hat on CDN) and their repositories IDs has been customized, you can change the configuration to use the official IDs instead of fixing the problem. You can also review the projected DNF upgrade transaction result in the logs to see what is going to happen, as this does not necessarily mean that the listed packages will not be upgraded. You can also install any missing packages after the in-place upgrade manually.
    Key: 9a2b05abf8f45fd7915e52542887bb334bb218ea

Does your system currently run kernel not provided by AlmaLinux

uname -r

?

4.18.0.-553.45.1.el8_10.x86_64

Oh, you are going to migrate from CentOS8 to AlmaLinux8. Please use almalinux-deploy.sh but not ELevate.
follow the guide at Migration Guide | AlmaLinux Wiki

Roger that but my system is disconexted from the internet… will this work with local repos instead of internet repos?

I have the EPEL, ELevate and AlmaLinux repos downloaded to an external drive.

So, yes, you can make it work.

  1. Connect the external drive to your system

  2. Omitting the drive is mounted under /opt it must match AlmaLinux repository directories structure, like:

/opt/
├── almalinux-release-latest-8.x86_64.rpm
├── RPM-GPG-KEY-AlmaLinux-8
└── 8
    ├── AppStream
    │   └── x86_64
    │       └── os
    │           ├── Packages
    │           └── repodata
    ├── BaseOS
    │   └── x86_64
    │       └── os
    │           ├── Packages
    │           └── repodata
    ├── extras
    │   └── x86_64
    │       └── os
    │           ├── Packages
    │           └── repodata
    └── PowerTools
        └── x86_64
            └── os
                ├── Packages
                └── repodata

where:
Packages - folder with corresponded repository all packages
repodata - folder with repository metadata

Note, it mandatory you download almalinux-release-latest-8.x86_64.rpm and RPM-GPG-KEY-AlmaLinux-8 from Index of /almalinux/ and place them into the root of /opt

  1. Follow the documentation at Migration Guide | AlmaLinux Wiki, and run the migration script with --local-repo, like:
# bash ./almalinux-deploy.sh --local-repo=file:///opt

Hey…

I had my external drive mounted at /run/media/root/LinuxUpdates and I ran updates form here without issue. I tried what you stated from /opt but its giving me the following error:

“Error: unknown option --local-repo=file///opt”

I have everything under /opt/8/ and the external drive is mounted to the /opt/8 directory as well. Is there something I’m missing?

You should:

  1. Follow the “Migrating an air-gapped machine” guide skipping steps to create AlmaLinux local mirror as you already have one

  2. Get the most resent almalinux-deploy.sh from almalinux-deploy/almalinux-deploy.sh at master · AlmaLinux/almalinux-deploy · GitHub

  3. Mount your external drive with AlmaLinux local mirror at any path convenient for you, let’s that be /run/media/root/LinuxUpdates

  4. Run the script:

sudo bash almalinux-deploy.sh --local-repo=file:///run/media/root/LinuxUpdates