<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Differences between search results in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Differences-between-search-results/m-p/132170#M36033</link>
    <description>&lt;P&gt;Try something like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup host-list | search NOT [search index=myindex earliest=-d@d latest=@d | fields host | dedup host]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It'll grab the list of unique host values from yesterday, build a huge (NOT ((host=A) OR (host=B) OR ...)) filter, and apply that to the results of the inputlookup.&lt;/P&gt;</description>
    <pubDate>Thu, 07 Nov 2013 10:30:01 GMT</pubDate>
    <dc:creator>martin_mueller</dc:creator>
    <dc:date>2013-11-07T10:30:01Z</dc:date>
    <item>
      <title>Differences between search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Differences-between-search-results/m-p/132169#M36032</link>
      <description>&lt;P&gt;Hello, &lt;BR /&gt;
I have a lookup table called host-list which has a list of all the hosts present in a network. I want to have a daily search that finds the list of hosts from where the log files are not generated. That is, I want to compare the list of all hosts present in host-list with the list of hosts from the log files and generate a table which shows all the "unresponsive" hosts, as in, the hosts which do not generate log files.&lt;/P&gt;

&lt;P&gt;I tried using map, diff, NOT and various other options but none seem to work. Any help?&lt;/P&gt;

&lt;P&gt;Sample search I used which didn't work:&lt;BR /&gt;
|inputlookup host-list | table host | where host NOT [search index=my_index earliest=-d@d latest=@d | fields hosts]&lt;/P&gt;</description>
      <pubDate>Thu, 07 Nov 2013 10:15:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Differences-between-search-results/m-p/132169#M36032</guid>
      <dc:creator>srinathd</dc:creator>
      <dc:date>2013-11-07T10:15:44Z</dc:date>
    </item>
    <item>
      <title>Re: Differences between search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Differences-between-search-results/m-p/132170#M36033</link>
      <description>&lt;P&gt;Try something like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup host-list | search NOT [search index=myindex earliest=-d@d latest=@d | fields host | dedup host]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It'll grab the list of unique host values from yesterday, build a huge (NOT ((host=A) OR (host=B) OR ...)) filter, and apply that to the results of the inputlookup.&lt;/P&gt;</description>
      <pubDate>Thu, 07 Nov 2013 10:30:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Differences-between-search-results/m-p/132170#M36033</guid>
      <dc:creator>martin_mueller</dc:creator>
      <dc:date>2013-11-07T10:30:01Z</dc:date>
    </item>
    <item>
      <title>Re: Differences between search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Differences-between-search-results/m-p/132171#M36034</link>
      <description>&lt;P&gt;This may perform faster&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;|inputlookup host-list | table host  | join type=outer host [search index=my_index earliest=-d@d latest=@d | stats count by hosts | rename hosts as host | fields - count| eval status="Responsive"]|eval status=COALESCE(status,"Unresponsive") | where status="Unresponsive"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The inner search will fetch distinct host from which data is coming and they add a field status="Responsive". You join this with your lookup data by host and with outer join, un-matched hosts will have status=NULL that we are transforming as "Unresponsive".&lt;/P&gt;</description>
      <pubDate>Thu, 07 Nov 2013 18:49:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Differences-between-search-results/m-p/132171#M36034</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2013-11-07T18:49:58Z</dc:date>
    </item>
  </channel>
</rss>

