Only one RHEL instance on Amazon EC2 may be registered to RHN

Solution Verified - Updated -

Environment

  • Red Hat Enterprise Linux (RHEL) 5.1 to 5.4 on  Amazon EC2 (Elastic Compute Cloud)
  • Red Hat Network(RHN)

Issue

  • Only one RHEL instance on Amazon EC2 may be registered to RHN

  • When registering a second RHEL instance on Amazon EC2 to RHN, a python traceback error message is received and the registration fails.

Resolution

Red Hat is aware of this issue.  It is due to a known limitation of the product entitlement for RHEL on EC2.  While a user may instantiate as many instances as they like with their RHEL on EC2 product purchase, only one may be registered on RHN at a time.  This issue affects RHEL5.4 and earlier images.  RHEL5.5 images may be updated outside of the RHN environment via an update structure in place in the cloud and, as such, are not affected by this limitation.  For non RHEL5.5 images, Red Hat suggests the following work around.

1. Instantiate one instance only.
2. Register it with RHN.
3. Use yum to update the instance.
4. Customize the instance per the company's needs.
5. Follow the Amazon how-to guide for bundling a custom AMI.
6. Start multiple instances of the customized AMI.

The procedure outlined above has two benefits that may not have been considered:

1. All running instances will be standardized on one corporate image.
2. Customers do not have to worry about getting charged for bandwidth usage to update each instance separately.

If it is absolutely essential to have multiple systems simultaneously registered against RHN, a new Amazon EC2 account with a unique login (and different email address) is required. Once a seperate account has been purchased, it can be used to register a second instance to RHN. We realize that this is not an ideal solution, and we are working on alternatives. However, we cannot give you an eta on when any such solution at this time.

Alternately:

If differently customized instances are required, and a separate Amazon EC2 account is undesireable for each, the following process may be used.

1. Log in to the appropriate RHN EC2 account. If there are multiple RHN accounts, make sure to use the correct login for the EC2 account.
2. Remove the profile for the system that was registered and updated in the steps above.
3. Start a new, unmodified instance, and log into it.
4. Cancel out the registration wizard, and register it to RHN from the command line with the following command:

# rhnreg_ks --profilename --username --password --nohardware

5. This system will take the place of previously registered instance, and yum can be used to update it via RHN.

Instructions for rolling a custom S3 backed image may be found on Amazon's "UserGuide".

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Comments