Feature #1611
open
Search for hosts without certain facts
Added by Greg Sutcliffe about 13 years ago.
Updated about 8 years ago.
Description
Some of my hosts have a fact "my_fact". I would like to be able to search for the hosts where this fact doesn't exist. This doesn't seemed to be possible within the current search system - things like "not has facts.my_fact" don't work, nor does "facts.myfact !~ *".
- Has duplicate Feature #1168: Ability to search for Facts (and Param) without providing a value added
- Status changed from New to Duplicate
- Category set to Search
- Status changed from Duplicate to New
This is a different issue from #1168 since that's resolved, but this is still relevant.
Steps to reproduce:
- Have a custom fact that is only on a few hosts (i.e. a fact confined to one osfamily)
- Try to search for hosts without that fact
I wrote a custom fact reboot_needed and now I want to know which hosts lack this fact. I tried the options Greg provided in the description and failed to find the hosts.
Also available in: Atom
PDF