tencent cloud

Feedback

Migrating CentOS to OpenCloudOS

Last updated: 2024-01-08 09:37:01

    Overview

    CentOS has officially discontinued support for CentOS 8 (see CentOS's official announcement). This document guides you migrating your servers from CentOS 8 to OpenCloudOS.
    OS Version
    EOL
    Impact
    CentOS 8
    January 1, 2022
    After end of maintenance, any software maintenance and support including bug fixes and feature updates are unavailable.

    Version Description

    OS versions supported for source servers

    OS
    Version
    CentOS 8 series
    CentOS_8.0_64-bit, CentOS_8.2_64-bit, CentOS_8.3_64-bit, CentOS_8.4_64-bit, and CentOS_8.2_ARM64
    If you are using CentOS 8 series, migrate it to OpenCloudOS 8.
    OS migration is not supported for CentOS Stream 8 public images.

    Limits

    OS migration is not supported in the following cases:
    A GUI is installed.
    An i686 RPM package is installed.
    Business may fail to run properly after migration under the following conditions:
    The business program is installed with and relies on a third-party RPM package.
    The business program relies on a fixed kernel version or has its own kernel module compiled. The target version after migration is tkernel4 (TK4) based on the v5.4 kernel. This version is later than the kernel versions of CentOS 8. Some old features may be updated in this new version. If your business program relies heavily on the kernel, we recommend that you know which features your business program actually relies on. You can also visit the OpenCloudOS community Bugtracker.
    The business program relies on a fixed GCC version. Currently, OpenCloudOS 8 is installed with GCC v8.5 by default.
    After migration, you need to restart the instance to enter the OpenCloudOS kernel.
    Migration does not affect data disks. Upgrade only in the OS layer does not involve any operation on data disks.

    Requirements

    500 MB of available memory
    10 GB of available space in the system disk

    Directions

    Preparation

    1. Create a snapshot to back up system disk data before you start migration.
    2. Check whether an i686 RPM package is installed and, if so, uninstall the package.
    3. Install Python 3 in your operating environment if you have not installed it. You can install Python 3 using a CentOS Vault repository.
    # cat <<EOF | sudo tee /tmp/centos8_vault.repo
    [c8_vault_baseos]
    name=c8_vault - BaseOS
    baseurl=https://mirrors.cloud.tencent.com/centos-vault/8.5.2111/BaseOS/\\$basearch/os/
    gpgcheck=0
    enabled=1
    [c8_vault_appstream]
    name=c8_vault - AppStream
    baseurl=https://mirrors.cloud.tencent.com/centos-vault/8.5.2111/AppStream/\\$basearch/os/
    gpgcheck=0
    enabled=1
    EOF
    # yum -y install python3 --disablerepo=* -c /tmp/centos8_vault.repo --enablerepo=c8_vault*

    Migration execution

    Do to following to migrate a CentOS 8 instance to OpenCloudOS 8:
    1. Log in to the target CVM instance. See Logging In To Linux Instance (Web Shell).
    2. Run the following command to install Python 3. If no YUM repository is available, install Python 3 using a CentOS Vault repository. For more information, see item 3 in the Preparing for the migration section.
    yum install -y python3
    3. Run one of the following commands based on your Python version to download the migration tool:
    #x86 version
    wget https://mirrors.opencloudos.tech/opencloudos/8.6/AppStream/x86_64/os/Packages/migrate2opencloudos-1.0-1.oc8.noarch.rpm
    #ARM version
    wget https://mirrors.opencloudos.tech/opencloudos/8/AppStream/aarch64/os/Packages/migrate2opencloudos-1.0-1.oc8.noarch.rpm
    4. Run the following command to install the migration tool. The command will create the migrate2opencloudos.py file in /usr/sbin.
    rpm -ivh migrate2opencloudos-1.0-1.oc8.noarch.rpm
    5. Run the following command to start migration:
    python3 /usr/sbin/migrate2opencloudos.py -v 8
    The migration takes some time. When the script execution is completed, the following information will be displayed:
    
    
    6. Restart the instance. See Restarting Instances.
    7. Check the migration result.
    Run the following command to check the OS release information:
    cat /etc/os-release
    The information shown in the figure below is displayed:
    
    
    Run the following command to check the kernel:
    uname -r
    The information shown in the figure below is displayed:
    
    By default, the kernel is the latest version of YUM.
    Run the following command to check YUM:
    yum makecache
    The information shown in the figure below is displayed:
    
    
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support