Migrate RHEL BYOL systems to AWS License-Included instances by using AWS MGN
Created by Mike Kuznetsov (AWS)
Summary
When you migrate your workloads to AWS by using AWS Application Migration Service (AWS MGN), you might have to lift and shift (rehost) your Red Hat Enterprise Linux (RHEL) instances and change the license from the default Bring Your Own License (BYOL) model to an AWS License Included (LI) model during migration. AWS MGN supports a scalable approach that uses Amazon Machine Image (AMI) IDs. This pattern describes how to accomplish the license change on RHEL servers during the rehost migration at scale. It also explains how to change the license for a RHEL system that’s already running on Amazon Elastic Compute Cloud (Amazon EC2).
Prerequisites and limitations
Prerequisites
Access to the target AWS account
AWS MGN initialized in the target AWS account and Region for the migration (not required if you have already migrated from your on-premises system to AWS)
A source RHEL server with a valid RHEL license
Architecture
This pattern covers two scenarios:
Migrating a system from on premises directly into an AWS LI instance by using AWS MGN. For this scenario, follow the instructions in the first epic (Migrate to LI instance - option 1) and third epic.
Changing the licensing model from BYOL to LI for a previously migrated RHEL system that’s already running on Amazon EC2. For this scenario, follow the instructions in the second epic (Migrate to LI instance - option 2) and third epic.
Note
The third epic involves reconfiguring the new RHEL instance to use the Red Hat Update Infrastructure (RHUI) servers provided by AWS. This process is the same for both scenarios.
Tools
AWS services
AWS Application Migration Service (AWS MGN) helps you rehost (lift and shift) applications to the AWS Cloud without change and with minimal downtime.
Epics
Task | Description | Skills required |
---|---|---|
Find the AMI ID of the RHEL AWS LI instance in the target Region. | Visit AWS Marketplace
| Cloud administrator |
Configure AWS MGN launch settings. |
AWS MGN will now use this version of the launch template to launch test or cutover instances. For more information, see the AWS MGN documentation. | Cloud administrator |
Validate settings. |
| Cloud administrator |
Launch the new LI instance. |
| Cloud administrator |
Task | Description | Skills required |
---|---|---|
Migrate your RHEL BYOL EC2 instance to an AWS LI instance. | You can switch RHEL systems that you previously migrated to AWS as BYOL to AWS LI instances by moving their disks (Amazon Elastic Block Store volumes) and attaching them to a new LI instance. To make this switch, follow these steps:
| Cloud administrator |
Task | Description | Skills required |
---|---|---|
Deregister the OS from the Red Hat subscription and license. | After migration and successful cutover, the RHEL system has to be removed from the Red Hat subscription to stop consuming the Red Hat license and avoid double billing. To remove RHEL OS from the Red Hat subscription, follow the process described in the Red Hat Subscription Management (RHSM) documentation
You can also disable the subscription manager plugin to stop checking the status of the subscription on every yum call. To do this, edit the configuration file | Linux or system administrator |
Replace the old update configuration (RHUI, Red Hat Satellite network, yum repositories) with the AWS-provided RHUI. | You must reconfigure the migrated RHEL system to use the AWS-provided RHUI servers. This gives you access to the RHUI servers within AWS Regions without requiring the external update infrastructure. The change involves the following process:
Here are the detailed steps and commands:
| Linux or system administrator |
Validate the configuration. | On the target migrated instance, verify that the new configuration is correct:
| Linux or system administrator |
Related resources
Get an AWS RHUI client package supporting IMDSv2
(Red Hat Knowledgebase article) Amazon EC2 launch templates (Amazon EC2 documentation)