<?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: How to compare search result of logs from production server to QA search result logs? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256628#M76830</link>
    <description>&lt;P&gt;Please some one answer the above request.&lt;/P&gt;</description>
    <pubDate>Fri, 09 Oct 2015 20:24:44 GMT</pubDate>
    <dc:creator>raghavendrasred</dc:creator>
    <dc:date>2015-10-09T20:24:44Z</dc:date>
    <item>
      <title>How to compare search result of logs from production server to QA search result logs?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256627#M76829</link>
      <description>&lt;P&gt;I want compare the 2 search result error logs and show the result.&lt;BR /&gt;
I want to compare based on "Error" log of 2 search result.&lt;/P&gt;

&lt;P&gt;One search result from prod:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;*NullPointerException*  index=prod | search log_level="ERROR" OR log_severity="Error" OR status&amp;gt;399 | stats earliest(_time) as FirstOccurence latest(_time) as LastOccurence count by static_msg | fieldformat FirstOccurence=strftime(FirstOccurence,"%m/%d/%y %H:%M:%S") | fieldformat LastOccurence =strftime(LastOccurence,"%m/%d/%y %H:%M:%S") | eval Error = static_msg | Table Error  count FirstOccurence LastOccurence | sort –count
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Search result from QA:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;*NullPointerException*  host=$host$ | search log_level="ERROR" OR log_severity="Error" OR status&amp;amp;gt;399 | stats earliest(_time) as FirstOccurence latest(_time) as LastOccurence count by static_msg | fieldformat FirstOccurence=strftime(FirstOccurence,"%m/%d/%y %H:%M:%S") | fieldformat LastOccurence =strftime(LastOccurence,"%m/%d/%y %H:%M:%S") | eval Error = static_msg | Table Error  count FirstOccurence LastOccurence | sort –count
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I tried diff like eval diff = prod - qa it's showing difference of count or number of entries displayed, but I am looking for actual log differences.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Oct 2015 14:13:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256627#M76829</guid>
      <dc:creator>raghavendrasred</dc:creator>
      <dc:date>2015-10-02T14:13:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare search result of logs from production server to QA search result logs?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256628#M76830</link>
      <description>&lt;P&gt;Please some one answer the above request.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Oct 2015 20:24:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256628#M76830</guid>
      <dc:creator>raghavendrasred</dc:creator>
      <dc:date>2015-10-09T20:24:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare search result of logs from production server to QA search result logs?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256629#M76831</link>
      <description>&lt;P&gt;Try something like this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| set diff [search *NullPointerException*  index=prod log_level="ERROR" OR log_severity="Error" OR status&amp;gt;399 | stats earliest(_time) as FirstOccurence latest(_time) as LastOccurence count by static_msg | convert ctime(*Occurrence) timeformat="%m/%d/%y %H:%M:%S" | rename  static_msg as Error| Table Error  count FirstOccurence LastOccurence] [search *NullPointerException* host=$host$ log_level="ERROR" OR log_severity="Error" OR status&amp;gt;399 | stats earliest(_time) as FirstOccurence latest(_time) as LastOccurence count by static_msg | convert ctime(*Occurrence) timeformat="%m/%d/%y %H:%M:%S" | rename  static_msg as Error| Table Error  count FirstOccurence LastOccurence ] | sort –count
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 09 Oct 2015 20:41:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256629#M76831</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2015-10-09T20:41:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare search result of logs from production server to QA search result logs?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256630#M76832</link>
      <description>&lt;P&gt;it not worked. &lt;/P&gt;

&lt;P&gt;I tried another way.. &lt;/P&gt;

&lt;P&gt;&lt;EM&gt;NullPointerException&lt;/EM&gt;  index=prod | search log_level="ERROR" OR log_severity="Error" OR status&amp;gt;399 |  stats count by static_msg | eval prod = static_msg | appendcols [search  &lt;EM&gt;NullPointerException&lt;/EM&gt;  host=$host$ | search log_level="ERROR" OR log_severity="Error" OR status&amp;gt;399 |  stats count by static_msg | eval qa = static_msg ] | eval err=if(prod == qa, "OK", "Error") &lt;/P&gt;

&lt;P&gt;it should work like vlookup, but it is not working..&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 07:32:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256630#M76832</guid>
      <dc:creator>raghavendrasred</dc:creator>
      <dc:date>2020-09-29T07:32:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare search result of logs from production server to QA search result logs?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256631#M76833</link>
      <description>&lt;P&gt;Thanks. now i got the result in single Error field. &lt;BR /&gt;
in result we have both the records of production and QA in single field as Error. The Error contains the 2 records with same message(like 2 entry with message "Failed to process ospp message."). Is it possible to highlight common records present in result.&lt;/P&gt;</description>
      <pubDate>Mon, 12 Oct 2015 16:58:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-search-result-of-logs-from-production-server-to/m-p/256631#M76833</guid>
      <dc:creator>raghavendrasred</dc:creator>
      <dc:date>2015-10-12T16:58:18Z</dc:date>
    </item>
  </channel>
</rss>

