<?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: Creating a metadata report gives wrong date in Reporting</title>
    <link>https://community.splunk.com/t5/Reporting/Creating-a-metadata-report-gives-wrong-date/m-p/114347#M2592</link>
    <description>&lt;P&gt;Use &lt;CODE&gt;time()&lt;/CODE&gt; instead of &lt;CODE&gt;now()&lt;/CODE&gt;. The latter gives you the time the search was launched, and can be trouble in certain constellations. Using &lt;CODE&gt;time()&lt;/CODE&gt; will also self-update the timestamp over the potentially long-running realtime search.&lt;/P&gt;</description>
    <pubDate>Tue, 01 Apr 2014 10:11:08 GMT</pubDate>
    <dc:creator>martin_mueller</dc:creator>
    <dc:date>2014-04-01T10:11:08Z</dc:date>
    <item>
      <title>Creating a metadata report gives wrong date</title>
      <link>https://community.splunk.com/t5/Reporting/Creating-a-metadata-report-gives-wrong-date/m-p/114346#M2591</link>
      <description>&lt;P&gt;I've found in the forum a nice way to query the metadata tables to check if our servers are writing logs,&lt;BR /&gt;&lt;BR /&gt;
the search term I'm using:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;| metadata type=hosts index=distrib | eval mytime=strftime (recentTime, "%y-%m-%d %H:%M:%S") | eval currentTime=strftime(now(), "%y-%m-%d %H:%M:%S") | eval minutesAgo=round(((now()-recentTime)/60),0)  | table sourcetype,host,lastTime,source,recentTime,mytime,currentTime,minutesAgo | where (abs(minutesAgo) &amp;gt; 1)&lt;/CODE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;

&lt;P&gt;which works great, but when I'm using it as a report, the generated report gives&lt;BR /&gt;
the current time as &lt;CODE&gt;70-01-01 02:00:00&lt;/CODE&gt;.&lt;BR /&gt;
The TimeRange configured is &lt;BR /&gt;&lt;BR /&gt;
 start time: rt-1m &lt;BR /&gt;&lt;BR /&gt;
 finish time: rt &lt;BR /&gt;&lt;/P&gt;

&lt;P&gt;(I've tried some other time variations, but always got the same result)&lt;/P&gt;

&lt;P&gt;(btw we're using Splunk 6) &lt;/P&gt;

&lt;P&gt;Can you provide any help on the subject?&lt;/P&gt;</description>
      <pubDate>Tue, 01 Apr 2014 09:11:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Creating-a-metadata-report-gives-wrong-date/m-p/114346#M2591</guid>
      <dc:creator>EldadDor</dc:creator>
      <dc:date>2014-04-01T09:11:05Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a metadata report gives wrong date</title>
      <link>https://community.splunk.com/t5/Reporting/Creating-a-metadata-report-gives-wrong-date/m-p/114347#M2592</link>
      <description>&lt;P&gt;Use &lt;CODE&gt;time()&lt;/CODE&gt; instead of &lt;CODE&gt;now()&lt;/CODE&gt;. The latter gives you the time the search was launched, and can be trouble in certain constellations. Using &lt;CODE&gt;time()&lt;/CODE&gt; will also self-update the timestamp over the potentially long-running realtime search.&lt;/P&gt;</description>
      <pubDate>Tue, 01 Apr 2014 10:11:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Creating-a-metadata-report-gives-wrong-date/m-p/114347#M2592</guid>
      <dc:creator>martin_mueller</dc:creator>
      <dc:date>2014-04-01T10:11:08Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a metadata report gives wrong date</title>
      <link>https://community.splunk.com/t5/Reporting/Creating-a-metadata-report-gives-wrong-date/m-p/114348#M2593</link>
      <description>&lt;P&gt;Did the trick &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Apr 2014 09:24:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Creating-a-metadata-report-gives-wrong-date/m-p/114348#M2593</guid>
      <dc:creator>EldadDor</dc:creator>
      <dc:date>2014-04-02T09:24:30Z</dc:date>
    </item>
  </channel>
</rss>

