<?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 Refining the search through lookup in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323687#M161407</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;Below is the search I am running on a set of servers in the lookup file , I don't want to run the search on all the hosts resulting from my main search that's why I am using the sub search (using inputlookup)&lt;/P&gt;

&lt;P&gt;index=cohl host=mdc*   [ | inputlookup COHL_Sourcetype | eval count=0 | stats count by sourcetype host]  | where count==0 | table sourcetype host&lt;/P&gt;

&lt;P&gt;But when I run the search I see the error :&lt;/P&gt;

&lt;P&gt;Regex: invalid UTF-8 string &lt;/P&gt;

&lt;P&gt;Can the experts let me know how to get rid of this error?&lt;/P&gt;</description>
    <pubDate>Mon, 10 Apr 2017 20:40:53 GMT</pubDate>
    <dc:creator>macadminrohit</dc:creator>
    <dc:date>2017-04-10T20:40:53Z</dc:date>
    <item>
      <title>Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323687#M161407</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;Below is the search I am running on a set of servers in the lookup file , I don't want to run the search on all the hosts resulting from my main search that's why I am using the sub search (using inputlookup)&lt;/P&gt;

&lt;P&gt;index=cohl host=mdc*   [ | inputlookup COHL_Sourcetype | eval count=0 | stats count by sourcetype host]  | where count==0 | table sourcetype host&lt;/P&gt;

&lt;P&gt;But when I run the search I see the error :&lt;/P&gt;

&lt;P&gt;Regex: invalid UTF-8 string &lt;/P&gt;

&lt;P&gt;Can the experts let me know how to get rid of this error?&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 20:40:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323687#M161407</guid>
      <dc:creator>macadminrohit</dc:creator>
      <dc:date>2017-04-10T20:40:53Z</dc:date>
    </item>
    <item>
      <title>Re: Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323688#M161408</link>
      <description>&lt;P&gt;Do you only want to run your search for host,sourcetype combination in subsearch where the value of field count in the subsearch is greater than 0? If yes then, you should include the where clause inside subsearch. Also, add a table command at the end of subsearch to only return the fields that you want to pass (and which are available in ) in base search.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=cohl  [ | inputlookup COHL_Sourcetype | eval count=0 | stats count by sourcetype host | where count=0 | table sourcetype host] 
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 10 Apr 2017 20:48:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323688#M161408</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-04-10T20:48:12Z</dc:date>
    </item>
    <item>
      <title>Re: Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323689#M161409</link>
      <description>&lt;P&gt;I tried your query but it doesn't work , to test it I placed 'where count &amp;gt;=0' , but it again gave me that error .&lt;/P&gt;

&lt;P&gt;index=cohl host=mdc* [ | inputlookup COHL_Sourcetype | eval count=0 | stats count by sourcetype host | where count ==0 | table sourcetype host]  &lt;/P&gt;

&lt;P&gt;The above query doesn't return anything.&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 21:37:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323689#M161409</guid>
      <dc:creator>macadminrohit</dc:creator>
      <dc:date>2017-04-10T21:37:16Z</dc:date>
    </item>
    <item>
      <title>Re: Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323690#M161410</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=cohl  [ | inputlookup COHL_Sourcetype | stats count by sourcetype host | where count=0 | table sourcetype host | format ] 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;OR&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=cohl  [ | inputlookup COHL_Sourcetype | stats count by sourcetype host | where count=0 | table sourcetype host | format  "" "" "" "" "" ""] 
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 10 Apr 2017 21:41:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323690#M161410</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-04-10T21:41:43Z</dc:date>
    </item>
    <item>
      <title>Re: Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323691#M161411</link>
      <description>&lt;P&gt;Have you verified there are no weird characters in your inputlookup table?&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 22:16:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323691#M161411</guid>
      <dc:creator>DalJeanis</dc:creator>
      <dc:date>2017-04-10T22:16:55Z</dc:date>
    </item>
    <item>
      <title>Re: Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323692#M161412</link>
      <description>&lt;P&gt;No I don't see anything weird in the lookup file. Any way I can remove those characters if any?&lt;/P&gt;</description>
      <pubDate>Tue, 11 Apr 2017 16:19:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323692#M161412</guid>
      <dc:creator>macadminrohit</dc:creator>
      <dc:date>2017-04-11T16:19:49Z</dc:date>
    </item>
    <item>
      <title>Re: Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323693#M161413</link>
      <description>&lt;P&gt;Splunk expects the lookup files to be in the UTF-8 character set, with normal line endings (Linux or Windows).&lt;BR /&gt;
Here are the specific requirements from the &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.5.3/Knowledge/ConfigureCSVlookups"&gt;Configure CSV lookups&lt;/A&gt; section of the Knowledge Manager manual. The file must also be in proper CSV format.&lt;/P&gt;

&lt;P&gt;Many text editors can find and "zap" weird characters and clean up the line endings in a file. I think Notepad++ may do this, as will BBEdit and others.&lt;/P&gt;</description>
      <pubDate>Wed, 12 Apr 2017 07:34:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323693#M161413</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2017-04-12T07:34:35Z</dc:date>
    </item>
    <item>
      <title>Re: Refining the search through lookup</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323694#M161414</link>
      <description>&lt;P&gt;What does this do:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup COHL_Sourcetype
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Does the above give you the error, too?  If so, you definitely need to clean the file.&lt;/P&gt;

&lt;P&gt;Also, the search definitely is broken even beyond this error.  At a minimum, this &lt;CODE&gt;| stats count by sourcetype host&lt;/CODE&gt; should be &lt;CODE&gt;stats count by sourcetype host | table sourcetype host&lt;/CODE&gt; or maybe &lt;CODE&gt;stats count by sourcetype host | table sourcetype&lt;/CODE&gt; or maybe &lt;CODE&gt;stats count by sourcetype host | table host&lt;/CODE&gt;.&lt;/P&gt;</description>
      <pubDate>Sat, 22 Apr 2017 22:42:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refining-the-search-through-lookup/m-p/323694#M161414</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-04-22T22:42:29Z</dc:date>
    </item>
  </channel>
</rss>

