Description of problem: It doesn't seem possible to search for virt-who hypervisors anymore. This seems to be an issue in 6.4.1, (possible 6.4.0) and 6.5 Version-Release number of selected component (if applicable): Sat 6.5.0 snap 5 How reproducible: Steps to Reproduce: 1. Configure virt-who to repo hypervisor hosts 2. In content Host, try to search "hypervisor=True" Actual results: No Results returned Expected results: Host which are virt-who reported hypervisors are returned. Additional info:
Here is what I found: Upstream - Hypervisor search works 6.5 (satellite-6.5.0-5.beta.el7sat.noarch) - Hypervisor search works 6.4 (satellite-6.4.1-2.el7sat.noarch) - Hypervisor search does not work It appears this is still an issue in 6.4, I will look for the commit that fixes this bug so we can pull it into 6.4
In 6.4, I believe the difference is what we are getting from candlepin: 6.4: irb(main):006:0> Host.find(6).subscription_facet.consumer_attributes => {"autoheal"=>false, "serviceLevel"=>nil, "releaseVer"=>nil, "environment"=>{"id"=>"20301a96cedcb1ef915e2149b300128a"}, "installedProducts"=>[], "guestIds"=>[]} Compare that with upstream (I had that available to check) irb(main):007:0> Host.find(8).subscription_facet.consumer_attributes => {"autoheal"=>true, "usage"=>nil, "role"=>nil, "addOns"=>[], "serviceLevel"=>"", "releaseVer"=>nil, "environment"=>{"id"=>"64c2cce3716a5bf67b0413fac95e5daa"}, "installedProducts"=>[], "guestIds"=>["b7503e93-0692-42aa-8ec9-32f2f5e99801"]} upstream has guest ids, which triggers our logic that the host is a hypervisor. I can look more, but there really isn't a big difference in the 6.5 and 6.4 katello code in this area, so I'm guessing it is related to what we receive from candlepin for the host's subscription facet
Looks like this is actually related to how we are parsing candlepin data, and will be fixed with https://bugzilla.redhat.com/show_bug.cgi?id=1651774
Connecting redmine issue https://projects.theforeman.org/issues/25407 from this bug
Verified fix in 6.5 snap 12 Searching with hypervisor=True and hypervisor=False give the correct result.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2019:1222