Chapter 7. Registering Clients to the Load Balancer


To balance the load of network traffic from clients, you must register the clients to the load balancer.

To register clients, proceed with one of the following procedures:

7.1. Registering Clients Using Host Registration

You can register hosts with Satellite using the host registration feature, the Satellite API, or Hammer CLI.

Procedure

  1. In the Satellite web UI, navigate to Hosts > Register Host.
  2. Click Generate to create the registration command.
  3. Click on the files icon to copy the command to your clipboard.
  4. Log in to the host you want register and run the previously generated command.
  5. Update subscription manager configuration for rhsm.baseurl and server.hostname:

    # subscription-manager config \
    --rhsm.baseurl=https://loadbalancer.example.com/pulp/content \
    --server.hostname=loadbalancer.example.com
  6. Check the /etc/yum.repos.d/redhat.repo file and ensure that the appropriate repositories have been enabled.

CLI procedure

  1. Generate the host registration command using the Hammer CLI:

    # hammer host-registration generate-command \
    --activation-keys "My_Activation_Key"

    If your hosts do not trust the SSL certificate of Satellite Server, you can disable SSL validation by adding the --insecure flag to the registration command.

    # hammer host-registration generate-command \
    --activation-keys "My_Activation_Key" \
    --insecure true
  2. Log in to the host you want register and run the previously generated command.
  3. Update subscription manager configuration for rhsm.baseurl and server.hostname:

    # subscription-manager config \
    --rhsm.baseurl=https://loadbalancer.example.com/pulp/content \
    --server.hostname=loadbalancer.example.com
  4. Check the /etc/yum.repos.d/redhat.repo file and ensure that the appropriate repositories have been enabled.

API procedure

  1. Generate the host registration command using the Satellite API:

    # curl -X POST https://satellite.example.com/api/registration_commands \
    --user "My_User_Name" \
    -H 'Content-Type: application/json' \
    -d '{ "registration_command": { "activation_keys": ["My_Activation_Key_1, My_Activation_Key_2"] }}'

    If your hosts do not trust the SSL certificate of Satellite Server, you can disable SSL validation by adding the --insecure flag to the registration command.

    # curl -X POST https://satellite.example.com/api/registration_commands \
    --user "My_User_Name" \
    -H 'Content-Type: application/json' \
    -d '{ "registration_command": { "activation_keys": ["My_Activation_Key_1, My_Activation_Key_2"], "insecure": true }}'

    Use an activation key to simplify specifying the environments. For more information, see Managing Activation Keys in Managing Content.

    To enter a password as command line argument, use username:password syntax. Keep in mind this can save the password in the shell history.

    For more information about registration see Registering a Host to Red Hat Satellite in Managing Hosts.

  2. Log in to the host you want register and run the previously generated command.
  3. Update subscription manager configuration for rhsm.baseurl and server.hostname:

    # subscription-manager config \
    --rhsm.baseurl=https://loadbalancer.example.com/pulp/content \
    --server.hostname=loadbalancer.example.com
  4. Check the /etc/yum.repos.d/redhat.repo file and ensure that the appropriate repositories have been enabled.

7.2. (Deprecated) Registering Clients Using the Bootstrap Script

To register clients, enter the following command on the client. You must complete the registration procedure for each client.

Prerequisite

Procedure

  • On Red Hat Enterprise Linux 8, enter the following command:

    # /usr/libexec/platform-python bootstrap.py \
    --activationkey="My_Activation_Key" \
    --enablerepos=satellite-client-6-for-rhel-8-<arch>-rpms \ 1
    --force \ 2
    --hostgroup="My_Hostgroup" \
    --location="My_Location" \
    --login=admin \
    --organization="My_Organization" \
    --puppet-ca-port 8141 \ 3
    --server loadbalancer.example.com
    1
    Replace <arch> with the client architecture, for example x86.
    2
    Include the --force option to register the client that has been previously registered to a standalone Capsule.
    3
    Include the --puppet-ca-port 8141 option if you use Puppet.
  • On Red Hat Enterprise Linux 7 or 6, enter the following command:

    # python bootstrap.py --login=admin \
    --activationkey="My_Activation_Key" \
    --enablerepos=rhel-7-server-satellite-client-6-rpms \
    --force \ 1
    --hostgroup="My_Hostgroup" \
    --location="My_Location" \
    --organization="My_Organization" \
    --puppet-ca-port 8141 \ 2
    --server loadbalancer.example.com
    1
    Include the --force option to register the client that has been previously registered to a standalone Capsule.
    2
    Include the --puppet-ca-port 8141 option if you use Puppet.

The script prompts for the password corresponding to the Satellite user name you entered with the --login option.

7.3. (Deprecated) Registering Clients Manually Using katello-ca-consumer RPM

To register clients manually, complete the following procedure on each client that you want to register.

Procedure

  1. Remove the katello-ca-consumer package if it is installed:

    # dnf remove 'katello-ca-consumer*'
  2. Install the katello-ca-consumer package from the load balancer:

    # dnf install http://loadbalancer.example.com/pub/katello-ca-consumer-latest.noarch.rpm
  3. Register the client and include the --serverurl and --baseurl options:

    # subscription-manager register \
    --activationkey="My_Activation_Key" \
    --baseurl=https://loadbalancer.example.com/pulp/content/ \
    --org="My_Organization" \
    --serverurl=https://loadbalancer.example.com/rhsm
Red Hat logoGithubRedditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.