<?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: Non-matching timestamps and wrong breaks on timestamp in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Non-matching-timestamps-and-wrong-breaks-on-timestamp/m-p/181468#M36402</link>
    <description>&lt;P&gt;What separates your data fields? Is this a csv file, or is there another common break you have to break the fields apart? If it is a csv, we have found that we must add a [^,] to the end of the timefield extraction. Also, if you are using the web interface then try using a regex to define where your event breaks should occur. Again, we use csv a lot and use the following regex to help define these when we do custom timestamp extraction:&lt;/P&gt;

&lt;P&gt;(?i)^(("(?:[^"]|"")&lt;EM&gt;"|[^,]&lt;/EM&gt;),){2}&lt;/P&gt;

&lt;P&gt;At least in our environment this has helped.&lt;/P&gt;</description>
    <pubDate>Thu, 23 Oct 2014 14:21:52 GMT</pubDate>
    <dc:creator>carpga</dc:creator>
    <dc:date>2014-10-23T14:21:52Z</dc:date>
    <item>
      <title>Non-matching timestamps and wrong breaks on timestamp</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Non-matching-timestamps-and-wrong-breaks-on-timestamp/m-p/181467#M36401</link>
      <description>&lt;P&gt;I have a log file with a timestamp at the beginning of an event in the format &lt;STRONG&gt;YYYY-MM-DD HH:MM:SS.mmm&lt;/STRONG&gt;.&lt;BR /&gt;
The automatic detection in the data preview does not work, as I have other timestamps in my file as well - so I decided to break on a break-before-regex:&lt;BR /&gt;
&lt;STRONG&gt;\d{4}-\d{2}-\d{2}\s-\d{2}:\d{2}:\d{2}.\d{3}&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;Splunk identifies the very first timestamp, but now identifies the whole log-file as one single event. I tried modifiers like (?m) or (?g), but they did not provide the result I expected. (?m) gives me back one event, (?g) gives me back event-breaks in the middle of an event i.e. at the wrong timestamps.&lt;/P&gt;

&lt;P&gt;I also tried to add &lt;STRONG&gt;TIME_PREFIX=^&lt;/STRONG&gt; in the props.conf, but that did not change a thing (it doesn't matter, if it's there or not).&lt;/P&gt;

&lt;P&gt;Furthermore, the timestamp I have in my events and the timestamp displayed by Splunk differ in an unexplicable way. &lt;BR /&gt;
Examples:&lt;BR /&gt;
&lt;STRONG&gt;Timestamp (Splunk) | Timestamp (Event)&lt;/STRONG&gt;&lt;BR /&gt;
10/9/01 12:58:30.013 PM | 2014-10-21 00:02:00.013&lt;BR /&gt;
10/9/01 5:29:33.824 PM | 2014-10-21 06:21:23.824&lt;BR /&gt;
10/9/01 5:29:30.133 PM | 2014-10-21 06:21:30.133&lt;/P&gt;

&lt;P&gt;What is going on here and how can I fix it?&lt;/P&gt;</description>
      <pubDate>Thu, 23 Oct 2014 13:10:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Non-matching-timestamps-and-wrong-breaks-on-timestamp/m-p/181467#M36401</guid>
      <dc:creator>ulrich_track</dc:creator>
      <dc:date>2014-10-23T13:10:30Z</dc:date>
    </item>
    <item>
      <title>Re: Non-matching timestamps and wrong breaks on timestamp</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Non-matching-timestamps-and-wrong-breaks-on-timestamp/m-p/181468#M36402</link>
      <description>&lt;P&gt;What separates your data fields? Is this a csv file, or is there another common break you have to break the fields apart? If it is a csv, we have found that we must add a [^,] to the end of the timefield extraction. Also, if you are using the web interface then try using a regex to define where your event breaks should occur. Again, we use csv a lot and use the following regex to help define these when we do custom timestamp extraction:&lt;/P&gt;

&lt;P&gt;(?i)^(("(?:[^"]|"")&lt;EM&gt;"|[^,]&lt;/EM&gt;),){2}&lt;/P&gt;

&lt;P&gt;At least in our environment this has helped.&lt;/P&gt;</description>
      <pubDate>Thu, 23 Oct 2014 14:21:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Non-matching-timestamps-and-wrong-breaks-on-timestamp/m-p/181468#M36402</guid>
      <dc:creator>carpga</dc:creator>
      <dc:date>2014-10-23T14:21:52Z</dc:date>
    </item>
    <item>
      <title>Re: Non-matching timestamps and wrong breaks on timestamp</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Non-matching-timestamps-and-wrong-breaks-on-timestamp/m-p/181469#M36403</link>
      <description>&lt;P&gt;Your regex also extracted the timestamp, but as with mine, the whole log was one event with this timestamp.&lt;BR /&gt;
It is a textfile, separators are spaces. Example given below:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;2014-10-21 05:01:52.964 INFO    at.bcm.skeis    [serverScheduler_Worker-1]   import successful
2014-10-21 05:01:54.538 INFO    at.bcm.skeis    [serverScheduler_Worker-1]  Reports successfully imported
2014-10-21 05:01:56.586 INFO    at.bcm.skeis    [serverScheduler_Worker-1]  Error during import!
2014-10-21 05:01:58.560 INFO    at.bcm.skeis    [serverScheduler_Worker-1]  
2014-10-21 06:03:44.307 INFO    at.bcm.skeis    [serverScheduler_Worker-5]  import successfull
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and how come, that the time is not extracted correctly? I mean there is a difference between October 2014 and September 2009 - I can't explain that.&lt;/P&gt;</description>
      <pubDate>Thu, 23 Oct 2014 14:55:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Non-matching-timestamps-and-wrong-breaks-on-timestamp/m-p/181469#M36403</guid>
      <dc:creator>ulrich_track</dc:creator>
      <dc:date>2014-10-23T14:55:27Z</dc:date>
    </item>
  </channel>
</rss>

