Red Hat Training

A Red Hat training course is available for Red Hat Satellite

7.5. Automated Host Registration with Activation Keys

The following steps show how to automatically register a host using an activation key. When the activation key has been created, you can apply it by using the subscription-manager utility during host registration on the Satellite Server. Note that the version of the subscription-manager utility installed must be 1.10 or higher. Prepare the host as described in Section 10.5.1, “Configuring a Host for Registration”, then follow the steps outlined in Procedure 7.11, “To Automatically Register a Host with an Activation Key:”.

Procedure 7.11. To Automatically Register a Host with an Activation Key:

  1. Clear any old registration data from the system:
    # subscription-manager clean
  2. Download and install a copy of the CA Certificate for the host from the Satellite Server:
    # rpm -Uvh http://satellite.example.com/pub/katello-ca-consumer-latest.noarch.rpm
  3. Register the system to the required organization on the Satellite Server. Use the --activationkey flag to register the system using the activation key. Enter the user authentication details when prompted.
    # subscription-manager register --org "Default_Organization" --activationkey "Test_Key"
  4. When the system is registered, it gains access to repository content but administrators will not be able perform package and errata management until the Katello agent has been installed on the client system. To do so, execute:
    # yum install katello-agent

Combining Multiple Activation Keys for Host Registration

You can use multiple activation keys when registering a content host. This allows you to create activation keys for specific subscription sets and then combine them according to content host requirements. For example, the following command registers a content host to the ACME organization with both VDC and OpenShift subscriptions:
# subscription-manager register --org "ACME" --activationkey "ak-VDC,ak-OpenShift"
If there are conflicting settings in activation keys, the rightmost key takes precedence.
  • Settings that conflict: Service Level, Release Version, Environment, Content View, and Product Content.
  • Settings that do not conflict and the host will get the union of them: Subscriptions and Host Collections.
  • Settings that influence the behavior of the key itself and not the host configuration: Content Host Limit and Auto-Attach.