Documentation survey

SUSE Multi-Linux Manager Server Migration to a Containerized Environment

1. Requirements and Considerations

1.1. General

  • To migrate a SUSE Multi-Linux Manager 4.3 Server to a container, you require a new machine with SL Micro 6.1 or SUSE Linux Enterprise Server 15 SP7 and mgradm installed.

  • An in-place migration from SUSE Multi-Linux Manager 4.3 to 5.1 is not supported, regardless of whether the chosen host operating system is SL Micro 6.1 or SUSE Linux Enterprise Server 15 SP7.

  • Before migrating from SUSE Multi-Linux Manager 4.3 to 5.1, any existing traditional clients including the traditional proxies must be migrated to Salt. For more information about migrating traditional SUSE Multi-Linux Manager 4.3 clients to Salt clients, see https://documentation.suse.com/suma/4.3/en/suse-manager/client-configuration/contact-methods-migrate-traditional.html.

  • Traditional contact protocol is no longer supported in SUSE Multi-Linux Manager 5.0 and later.

This guide only covers the migration from SUSE Multi-Linux Manager 4.3 to 5.1. Migrating an existing SUSE Multi-Linux Manager 5.1 instance to the same version while switching the host operating system from SL Micro 6.1 to SUSE Linux Enterprise Server 15 SP7, or vice versa, is not handled by the mgradm migrate command.

1.2. Hostnames

  • The current migration procedure does not include functionality for renaming hostnames. As a result, the fully qualified domain name (FQDN) of the new server will remain the same as that of the old server.

  • The IP address must remain unchanged to ensure that the clients can contact the server.

    After the migration, it will be necessary to manually update the DHCP and DNS records to point to the new server.

1.3. GPG Keys

  • Self trusted GPG keys are not migrated.

  • GPG keys that are trusted in the RPM database only are not migrated. Thus synchronizing channels with spacewalk-repo-sync can fail.

  • The administrator must migrate these keys manually from the 4.3 installation to the container host after the actual server migration.

    Procedure: Manual Migration of the 4.3 GPG Keys to New Server
    1. Copy the keys from the 4.3 server to the container host of the new server.

    2. Later, add each key to the migrated server with the command mgradm gpg add <PATH_TO_KEY_FILE>.

2. Migration

2.1. Prepare SUSE Multi-Linux Manager 5.1 Server Host

Do not pre-install SUSE Multi-Linux Manager on the prepared SL Micro 6.1 or SUSE Linux Enterprise Server 15 SP7 system.

The migration process is designed to perform the server installation automatically. Running mgradm install and then mgradm migrate is not supported and will lead to an unsupported system state.

In the following steps, we are only preparing the host system, not installing the actual SUSE Multi-Linux Manager 5.1 Server.

2.1.1. Prepare SL Micro 6.1 Host

2.1.1.1. Download the installation media
Procedure: Downloading the Installation Media
  1. Locate the SL Micro 6.1 installation media at https://www.suse.com/download/sle-micro/, and download the appropriate media file.

  2. Prepare a DVD or USB flash drive with the downloaded .iso image for installation.

2.1.1.2. Install SL Micro 6.1

For more information about preparing your machines (virtual or physical), see the SL Micro Deployment Guide.

Procedure: Installing SL Micro 6.1
  1. Insert the DVD or USB flash drive (USB disk or key) containing the installation image for SLE Micro 6.1.

  2. Boot or reboot your system.

  3. Use the arrow keys to select Installation.

  4. Adjust Keyboard and language.

  5. Click the checkbox to accept the license agreement.

  6. Click Next to continue.

  7. Select the registration method. For this example, we will register the server with SUSE Customer Center.

    The SUSE Multi-Linux Manager 5.1 containers are installed as extensions. Depending on the specific extension needed from the list below, additional SUSE Customer Center registration codes will be required for each.

    • SUSE Multi-Linux Manager 5.1 Server

    • SUSE Multi-Linux Manager 5.1 Proxy

    • SUSE Multi-Linux Manager 5.1 Retail Branch Server

    The SL Micro 6.1 entitlement is included within the SUSE Multi-Linux Manager entitlement, so it does not require a separate registration code.

  8. Enter your SUSE Customer Center email address.

  9. Enter your registration code for SL Micro 6.1.

  10. Click Next to continue.

  11. To install a proxy, select the SUSE Multi-Linux Manager 5.1 Proxy extension; to install a server, select the SUSE Multi-Linux Manager 5.1 Server extension Checkbox.

  12. Click Next to continue.

  13. Enter your SUSE Multi-Linux Manager 5.1 extension registration code.

  14. Click Next to continue.

  15. On the NTP Configuration page click Next.

  16. On the Authentication for the System page enter a password for the root user. Click Next.

  17. On the Installation Settings page click Install.

This concludes installation of SL Micro 6.1 and SUSE Multi-Linux Manager 5.1 as an extension.

2.1.1.3. OPTIONAL: Registration from the command line

If you added SUSE Multi-Linux Manager 5.1 as an extension during SL Micro 6.1 installation then you can skip this procedure. However, optionally you may skip registration during SL Micro 6.1 installation by selecting the Skip Registration button. This section provides steps on registering your products after SL Micro 6.1 installation.

The following steps register a SUSE Multi-Linux Manager 5.1 extension with the x86-64 architecture and thus require a registration code for the x86-64 architecture. To register ARM or s390x architectures use the correct registration code.

Procedure: Registering from the Command Line
  1. List available extensions with the following command:

    transactional-update --quiet register --list-extensions
  2. From the list of available extensions, select the one you wish to install:

    1. If installing the Server, use your SUSE Multi-Linux Manager Server Extension 5.1 x86_64 registration code with following command:

      transactional-update register -p Multi-Linux-Manager-Server/5.1/x86_64 -r <reg_code>
    2. If installing the Proxy, use your SUSE Multi-Linux Manager Proxy Extension 5.1 x86_64 registration code with following command:

      transactional-update register -p Multi-Linux-Manager-Proxy/5.1/x86_64 -r <reg_code>
  3. Reboot.

2.1.1.4. Update the system
Procedure: Updating the System
  1. Log in as root.

  2. Run transactional-update:

    transactional-update
  3. Reboot.

SL Micro is designed to update itself automatically by default and will reboot after applying updates. However, this behavior is not desirable for the SUSE Multi-Linux Manager environment. To prevent automatic updates on your server, SUSE Multi-Linux Manager disables the transactional-update timer during the bootstrap process.

If you prefer the SL Micro default behavior, enable the timer by running the following command:

systemctl enable --now transactional-update.timer

2.1.2. Prepare SUSE Linux Enterprise Server 15 SP7 Host

Alternatively, you can deploy SUSE Multi-Linux Manager on SUSE Linux Enterprise Server 15 SP7.

The following procedure describes the main steps of the installation process.

Procedure: Installing SUSE Multi-Linux Manager Extensions on SUSE Linux Enterprise Server 15 SP7
  1. Locate and download SUSE Linux Enterprise Server 15 SP7 .iso at https://www.suse.com/download/sles/.

  2. Make sure that you have regsistration codes both for the host operating system (SUSE Linux Enterprise Server 15 SP7) and extensions

  3. Start the installation of SUSE Linux Enterprise Server 15 SP7.

    1. On the Language, keyboard and product selection select the product to install.

    2. On the License agreement read the agreement and check I Agree to the License Terms.

  4. Select the registration method. For this example, we will register the server with SUSE Customer Center.

  5. Enter your SUSE Customer Center email address.

  6. Enter your registration code for SUSE Linux Enterprise Server 15 SP7.

  7. Click Next to continue.

    Please note that for SUSE Linux Enterprise Server 15 SP7, you are required to have a valid SUSE Linux Enterprise Server subscription and corresponding registration code, which you must provide on this screen. You will be required to enter the SUSE Multi-Linux Manager Extension registration code below.

  8. In the screen Extensions and Modules Selection check the following:

    • Select the SUSE Multi-Linux Manager Server Extension to install the Server, or the SUSE Multi-Linux Manager Proxy Extension to install the Proxy.

    • Basesystem Module

    • Containers Module

  9. Click Next to continue.

  10. Enter your SUSE Multi-Linux Manager 5.1 extension registration code.

  11. Click Next to continue.

  12. Complete the installation.

  13. When the installation completes, log in to the newly installed server as root.

  14. Update the System (optional, if the system was not set to download updates during install):

    zypper up
  15. Reboot.

  16. Log in as root and install podman plus mgradm and mgradm-bash-completion (if not already automatically installed):

    zypper install podman mgradm mgradm-bash-completion
  17. Start the Podman service by rebooting the system, or running a command:

    systemctl enable --now podman.service

2.2. SSH Connection Preparation

This step ensures that the new SUSE Multi-Linux Manager 5.1 Server can connect to the existing 4.3 Server over SSH without requiring a password. It involves generating and configuring SSH keys, setting up an SSH agent, and copying the public key to the old server. This setup is required for the migration process to run without manual intervention.

Procedure: Preparing the SSH Connection
  1. Ensure that for root an SSH key exists on the new 5.1 server. If a key does not exist, create it with:

    ssh-keygen -t rsa
  2. The SSH configuration and agent should be ready on the new server for a connection to the 4.3 server that does not prompt for a password.

    eval $(ssh-agent); ssh-add

    To establish a connection that does not prompt for a password, the migration script relies on an SSH agent running on the new server. If the agent is not active yet, initiate it by running eval $(ssh-agent). Then add the SSH key to the running agent with ssh-add followed by the path to the private key. You will be prompted to enter the password for the private key during this process.

  3. Copy the public SSH key to the SUSE Multi-Linux Manager 4.3 Server (<oldserver.fqdn>) with ssh-copy-id. Replace <oldserver.fqdn> with the FQDN of the 4.3 server:

    ssh-copy-id <old server.fqdn>

    The SSH key will be copied into the old server’s ~/.ssh/authorized_keys file. For more information, see the ssh-copy-id manpage.

  4. Establish an SSH connection from the new server to the old SUSE Multi-Linux Manager Server to check that no password is needed. Also there must not by any problem with the host fingerprint. In case of trouble, remove old fingerprints from the ~/.ssh/known_hosts file. Then try again. The fingerprint will be stored in the local ~/.ssh/known_hosts file.

2.3. Perform the Migration

When planning your migration from SUSE Multi-Linux Manager 4.3 to SUSE Multi-Linux Manager 5.1, ensure that your target instance meets or exceeds the specifications of the old setup.

This includes, but is not limited to, memory (RAM), CPU Cores, Storage, and Network Bandwidth.

Procedure: Performing the Migration
  1. This step is optional. If custom persistent storage is required for your infrastructure, use the mgr-storage-server tool. For more information about mgr-storage-server, see installation-and-upgrade:hardware-requirements.adoc#install-hardware-requirements-storage.

  2. Execute the following command to install a new SUSE Multi-Linux Manager server. Replace <oldserver.fqdn> with the FQDN of the 4.3 server:

    Make sure to upgrade your 4.3 server and apply all available updates before starting the migration process. Additionally, remove any unnecessary channels to help reduce the overall migration time.

    The migration can take a very long time depending on the amount of data that needs to be replicated. To reduce downtime it is possible to run the migration multiple times in a process of initial replication, re-replication, or final replication and switch over while all the services on the old server can stay up and running.

    Only during the final migration the processes on the old server need to be stopped.

    For all non-final replications add the parameter --prepare to prevent the automatic stopping the services on the old server. For example on SUSE Multi-Linux Manager server:

    mgradm migrate podman <oldserver.fqdn> --prepare
Procedure: Final Migration
  1. Stop the SUSE Multi-Linux Manager services on 4.3 Server:

    spacewalk-service stop
  2. Stop the PostgreSQL service on 4.3 Server:

    systemctl stop postgresql
  3. Perform the migration on SUSE Multi-Linux Manager server

    mgradm migrate podman <oldserver.fqdn>
  4. Migrate trusted SSL CA certificates.

2.3.1. Migration of the Certificates

Trusted SSL CA certificates that were installed as part of an RPM and stored on SUSE Multi-Linux Manager 4.3 in the /usr/share/pki/trust/anchors/ directory will not be migrated. Because SUSE does not install RPM packages in the container, the administrator must migrate these certificate files manually from the 4.3 installation after the migration.

Procedure: Migrating the Certificates
  1. Copy the file from the 4.3 server to the new server. For example, as /local/ca.file.

  2. Copy the file into the container with:

    mgrctl cp /local/ca.file server:/etc/pki/trust/anchors/

After successfully running the mgradm migrate command, the Salt setup on all clients will still point to the old 4.3 server.

To redirect them to the 5.1 server, it is required to rename the new server at the infrastructure level (DHCP and DNS) to use the same FQDN and IP address as 4.3 server.

Adjusting the IP address can be avoided if the latest version of the minion is installed on the clients, as the newer version can automatically re-connect with the server using only the FQDN.

SUSE Multi-Linux Manager 5.1 introduces a rebranded set of client tools for all supported operating systems. This transition is seamless, and users performing a new product synchronization should only notice the updated channel names.

Channels named SUSE Manager Client Tools for XYZ, used by clients previously registered with SUSE Multi-Linux Manager 4.3 or 5.0, are no longer available in version 5.1 and will no longer receive updates in 5.1.

Although the legacy channels remain assigned to existing clients after migration, the corresponding repositories have been removed.

To ensure continued updates, users must:

  • Mirror the new SUSE Multi-Linux Manager Client Tools for XYZ channels for the relevant products and assign them to the appropriate clients.

  • Unassign the outdated SUSE Manager Client Tools for XYZ channels.

This also means that any CLM projects based on the old client tools must be adjusted accordingly.