Listing hosts via host_collection based search query yields to wrong results in Red Hat Satellite 6

Solution Verified - Updated -

Issue

  • Common host between host_collections is not excluded while listing the hosts via hammer as displayed below:

    # hammer host list --search 'host_collection = test1 and host_collection != test2'
    ---|-------------|------------------|------------|--------------|----------------------
    ID | NAME        | OPERATING SYSTEM | HOST GROUP | CONTENT VIEW | LIFECYCLE ENVIRONMENT
    ---|-------------|------------------|------------|--------------|----------------------
    58 | host1       |                  |            |              |                      
    57 | host2       |                  |            |              |                      
    ---|-------------|------------------|------------|--------------|----------------------
    
    • Note: In the above example, host2 is a common host in both host_collections test1 and test2 and is still listed despite it being part of the excluded host collection.

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