Host registration using bootstrap script fails with [0 element in array for search key 'title="RHEL 5"' in API '/api/v2/operatingsystems'.] in Red Hat Satellite 6

Solution Verified - Updated -

Issue

  • While registering the host to Red Hat Satellite 6 using bootstrap method getting Operating System error as follows:

        # ./bootstrap.py --login=satadmin --password=satpassword --server=satellite.example.com --location="ABC" --organization="RedHat" --activationkey="RHEL AK" --operatingsystem="RHEL 5" --hostgroup="RHELHG"
        Foreman Bootstrap Script
        This script is designed to register new systems or to migrate an existing system to a Foreman server with Katello
        .
        .
        .
        [RUNNING], [2020-07-14 18:45:17], [rpm -Uvh http://satellite.example.com/pub/katello-ca-consumer-latest.noarch.rpm]
        Retrieving http://satellite.example.com/pub/katello-ca-consumer-latest.noarch.rpm
        Preparing... ##################################################
        katello-ca-consumer-satellite##################################################
        [SUCCESS], [2020-07-14 18:45:18], [rpm -Uvh http://satellite.example.com/pub/katello-ca-consumer-latest.noarch.rpm], completed successfully.
        [NOTIFICATION], [2020-07-14 18:45:18], [Writing FQDN katello-fact]
        [ERROR], [2020-07-14 18:45:19], EXITING: [0 element in array for search key 'title="RHEL 5"' in API '/api/v2/operatingsystems'. Please note that all searches are case-sensitive.] failed to execute properly.
        [ERROR], [2020-07-14 18:45:19], EXITING: [Please also ensure that the user has permissions to view the searched objects. Fatal error.] failed to execute properly.
    

Environment

  • Red Hat Satellite 6.

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content