<?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 Search Timestamp in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77501#M19571</link>
    <description>&lt;P&gt;I'm having problems with a remote file import using a forwarder, where the file time date stamp is in UK format dd/mm/yyyy 17:00:00 and the first field in the CSV is also dd/mm/yyy 17:00:00 but the first entry for all items in splunk is in mm/dd/yyyy format. &lt;/P&gt;

&lt;P&gt;Problem is that when I do a search on this csv in splunk, the file date stamps are not indexing correctly. See below. Todays entries are coming out of the splunk index as February. (csv file only now contains entries for today in it)&lt;/P&gt;

&lt;P&gt;10/02/2012 17:32:14.000     02/10/2012 17:32:14,fred.blogs,,,,,,,,,,,&lt;/P&gt;

&lt;P&gt;First column in the search is incorrect and the date splunk seems to be indexing on. Second date is correct and as per the CSV file. &lt;/P&gt;

&lt;P&gt;I've seen some posts that talk about changing the prop.conf file here's what i've added to the CSV section of e:\Program File\Splunk\etc\system\default\prop.conf&lt;/P&gt;

&lt;P&gt;--------------------cut-----------------------&lt;/P&gt;

&lt;H6&gt;# NON-LOG FILES&lt;/H6&gt;

&lt;P&gt;[source::....(jar)(.\d+)?]&lt;BR /&gt;
sourcetype = source_archive&lt;/P&gt;

&lt;P&gt;[source::....(css|htm|html|sgml|shtml|template)]&lt;BR /&gt;
sourcetype = web&lt;/P&gt;

&lt;P&gt;[source::....csv]&lt;BR /&gt;
sourcetype = csv&lt;BR /&gt;
TIME_FORMAT=%m/%d/%Y %H:%M:%S&lt;/P&gt;

&lt;P&gt;--------------------cut-----------------------&lt;/P&gt;

&lt;P&gt;This hasn't fixed my problem. So I've either edited the wrong file or I've added the wrong format info or both.&lt;/P&gt;

&lt;P&gt;Any body know how I can fix this issue? I'm stumped.&lt;/P&gt;

&lt;P&gt;The confusing thing is that this was working when the csv had loads of data in it, going back several months. I was about to go into production so I flattened all the logs to start with clean data using&lt;/P&gt;

&lt;P&gt;.\splunk clean&lt;/P&gt;

&lt;P&gt;All my files now only have from today in them.&lt;/P&gt;

&lt;P&gt;My other log files from syslog and ais are working fine it's just this csv that's causing problems. I guess there isn't enough data in the new file for the system to auto detect correct date format.&lt;/P&gt;

&lt;P&gt;Cheers&lt;/P&gt;

&lt;P&gt;Simon&lt;/P&gt;</description>
    <pubDate>Tue, 02 Oct 2012 17:24:38 GMT</pubDate>
    <dc:creator>simon_pytches</dc:creator>
    <dc:date>2012-10-02T17:24:38Z</dc:date>
    <item>
      <title>Search Timestamp</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77501#M19571</link>
      <description>&lt;P&gt;I'm having problems with a remote file import using a forwarder, where the file time date stamp is in UK format dd/mm/yyyy 17:00:00 and the first field in the CSV is also dd/mm/yyy 17:00:00 but the first entry for all items in splunk is in mm/dd/yyyy format. &lt;/P&gt;

&lt;P&gt;Problem is that when I do a search on this csv in splunk, the file date stamps are not indexing correctly. See below. Todays entries are coming out of the splunk index as February. (csv file only now contains entries for today in it)&lt;/P&gt;

&lt;P&gt;10/02/2012 17:32:14.000     02/10/2012 17:32:14,fred.blogs,,,,,,,,,,,&lt;/P&gt;

&lt;P&gt;First column in the search is incorrect and the date splunk seems to be indexing on. Second date is correct and as per the CSV file. &lt;/P&gt;

&lt;P&gt;I've seen some posts that talk about changing the prop.conf file here's what i've added to the CSV section of e:\Program File\Splunk\etc\system\default\prop.conf&lt;/P&gt;

&lt;P&gt;--------------------cut-----------------------&lt;/P&gt;

&lt;H6&gt;# NON-LOG FILES&lt;/H6&gt;

&lt;P&gt;[source::....(jar)(.\d+)?]&lt;BR /&gt;
sourcetype = source_archive&lt;/P&gt;

&lt;P&gt;[source::....(css|htm|html|sgml|shtml|template)]&lt;BR /&gt;
sourcetype = web&lt;/P&gt;

&lt;P&gt;[source::....csv]&lt;BR /&gt;
sourcetype = csv&lt;BR /&gt;
TIME_FORMAT=%m/%d/%Y %H:%M:%S&lt;/P&gt;

&lt;P&gt;--------------------cut-----------------------&lt;/P&gt;

&lt;P&gt;This hasn't fixed my problem. So I've either edited the wrong file or I've added the wrong format info or both.&lt;/P&gt;

&lt;P&gt;Any body know how I can fix this issue? I'm stumped.&lt;/P&gt;

&lt;P&gt;The confusing thing is that this was working when the csv had loads of data in it, going back several months. I was about to go into production so I flattened all the logs to start with clean data using&lt;/P&gt;

&lt;P&gt;.\splunk clean&lt;/P&gt;

&lt;P&gt;All my files now only have from today in them.&lt;/P&gt;

&lt;P&gt;My other log files from syslog and ais are working fine it's just this csv that's causing problems. I guess there isn't enough data in the new file for the system to auto detect correct date format.&lt;/P&gt;

&lt;P&gt;Cheers&lt;/P&gt;

&lt;P&gt;Simon&lt;/P&gt;</description>
      <pubDate>Tue, 02 Oct 2012 17:24:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77501#M19571</guid>
      <dc:creator>simon_pytches</dc:creator>
      <dc:date>2012-10-02T17:24:38Z</dc:date>
    </item>
    <item>
      <title>Re: Search Timestamp</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77502#M19572</link>
      <description>&lt;P&gt;That TIME_FORMAT setting should have been placed in props.conf on your indexer.  Is that the case?&lt;/P&gt;</description>
      <pubDate>Tue, 02 Oct 2012 19:44:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77502#M19572</guid>
      <dc:creator>emiller42</dc:creator>
      <dc:date>2012-10-02T19:44:25Z</dc:date>
    </item>
    <item>
      <title>Re: Search Timestamp</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77503#M19573</link>
      <description>&lt;P&gt;Your TIME_FORMAT says that the CSV is in month-day-year format! I think you want&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;TIME_FORMAT=%d/%m/%Y %H:%M:%S
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 02 Oct 2012 22:40:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77503#M19573</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2012-10-02T22:40:18Z</dc:date>
    </item>
    <item>
      <title>Re: Search Timestamp</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77504#M19574</link>
      <description>&lt;P&gt;Oops thanks, good spot that's what happens when you spend too long staring at something. I've changed it as above but still get same thing. Have tried restarting splunk. Still appears the same in the search (thinks today transactions are March)&lt;/P&gt;

&lt;P&gt;I'm not sure this is the correct file or section in the prop.conf or even if I've edited the correct prop.conf instance. The file I changed was on the Splunk server (not the forwarder) under&lt;/P&gt;

&lt;P&gt;e:\Program Files\Splunk\etc\system\default\prop.conf&lt;/P&gt;

&lt;P&gt;Unless I need to re-index somehow :s&lt;/P&gt;

&lt;P&gt;Cheers&lt;/P&gt;

&lt;P&gt;Simon&lt;/P&gt;</description>
      <pubDate>Wed, 03 Oct 2012 10:28:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77504#M19574</guid>
      <dc:creator>simon_pytches</dc:creator>
      <dc:date>2012-10-03T10:28:13Z</dc:date>
    </item>
    <item>
      <title>Re: Search Timestamp</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77505#M19575</link>
      <description>&lt;P&gt;The file should be called "props.conf", not "prop.conf".&lt;/P&gt;

&lt;P&gt;Also these settings are applied at index-time, so any changes you make will NOT have any effect on data that has already been indexed.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Oct 2012 11:02:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Search-Timestamp/m-p/77505#M19575</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2012-10-03T11:02:28Z</dc:date>
    </item>
  </channel>
</rss>

