HOME » Migration from KUSANAGI to KUSANAGI » How to migrate from CentOS Stream 8 based KUSANAGI 9 to AlmaLinux OS 8 with scripts provided by AlmaLinux

How to migrate from CentOS Stream 8 based KUSANAGI 9 to AlmaLinux OS 8 with scripts provided by AlmaLinux

AlmaLinux provides a script to migrate from CentOS Stream to AlmaLinux.
This article will show you how to use that script to migrate from CentOS Stream 8-based KUSANAGI 9 to AlmaLinux OS 8-based.

Points to keep in mind when performing migration

  • Make backups before migration
    As a precaution when performing migration, be sure to take snapshots or other backups before performing the migration.
    If migration should fail, it may be very difficult to recover, so please be sure to make backups before executing the migration.
  • Scripts do not support CMS migration
    The scripts provided by AlmaLinux perform OS migration, not migration of all applications installed on the OS.
    In some cases, even if the OS migration succeeds, the CMS may not work properly.
    If this happens, please check the KUSANAGI user group below.

https://users.kusanagi.tokyo/

  • The image on the cloud side is still KUSANAGI 9 based on CentOS Stream 8
    The original information kept by the cloud side is CentOS Stream 8 based KUSANAGI 9, and even if migration is performed, it will not become AlmaLinux OS 8 based KUSANAGI 9, which is provided by the cloud vendor.
    Of course, the environment after migration is equivalent to that of AlmaLinux OS 8 based KUSANAGI 9 provided by the cloud vendor, and there is no difference in functionality.

Confirmation of environment before migration

Check the KUSANAGI 9 environment before migration.

$ cat /etc/redhat-release
CentOS Stream release 8
$

The operating system is listed as CentOS Stream release 8.
Thus, if you can confirm that the OS is CentOS Stream 8, you can migrate.

Migration Execution

Follow the steps on the official website below to perform the migration.

Migration Guide | AlmaLinux Wiki

First, run dnf update -y with administrator privileges to up-to-date the OS.

sudo dnf update -y

Then download the shell script.

curl -O https://raw.githubusercontent.com/AlmaLinux/almalinux-deploy/master/almalinux-deploy.sh

When the download is complete, run the downloaded shell script with the -d option with administrative privileges.

sudo bash almalinux-deploy.sh -d

It will take some time for the execution to complete, so be careful not to shut down the environment during this time.
If the message “Migration to AlmaLinux is completed” is displayed, the process has been successfully completed.
The environment is rebooted to complete the process.

sudo reboot

Confirmation of post-migration environment

Login to the environment again and confirm that the OS has switched.

$ cat /etc/redhat-release
AlmaLinux release 8.9 (Midnight Oncilla)
$

The operating system is listed as AlmaLinux release 8.9.
Thus, we have confirmed that the OS has switched to AlmaLinux OS 8.

These are the steps for migrating from CentOS Stream 8 to AlmaLinux OS 8 with the script provided by AlmaLinux.