<?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 Multiple time formats in one sourcetype - failed to extract timestamp in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Multiple-time-formats-in-one-sourcetype-failed-to-extract/m-p/544747#M90870</link>
    <description>&lt;P&gt;Hello Dear Splunkers &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;Recently we got reported issue when our indexers are reporting multiple issues with timestamp extraction. I found out that one log file (with dedicated sourcetype) has multiple different formats of time. Therefore we are not able determine correct configuration for sourcetype iin props.conf&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Beginning of those events look like this:&lt;BR /&gt;1.&amp;nbsp;&lt;SPAN class="h"&gt;2021-03-22T16:15:31.995&lt;/SPAN&gt;&lt;SPAN&gt;+0800&lt;/SPAN&gt;&lt;BR /&gt;2.&amp;nbsp;&lt;SPAN&gt;[DEBUG] &lt;/SPAN&gt;&lt;SPAN class="h"&gt;2021-03-22 16:15:32.075&lt;/SPAN&gt;&lt;BR /&gt;3.&amp;nbsp;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class="t"&gt;2021-03-22T02:15:29.217&lt;/SPAN&gt; &lt;SPAN class="t"&gt;CST&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;Its input from *.stdout log file therefore there is a lot of different types of events.&lt;BR /&gt;I would like to skip letter "T" in time format definition but sadly I did not find anything that can help us.&lt;BR /&gt;Anybody dealt with situation like this?&lt;BR /&gt;Many thanks&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Denis&amp;nbsp;&amp;nbsp;&lt;BR /&gt;The biggest problem seems to be in letter "T".&lt;/P&gt;</description>
    <pubDate>Mon, 22 Mar 2021 10:13:14 GMT</pubDate>
    <dc:creator>Denis_B</dc:creator>
    <dc:date>2021-03-22T10:13:14Z</dc:date>
    <item>
      <title>Multiple time formats in one sourcetype - failed to extract timestamp</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Multiple-time-formats-in-one-sourcetype-failed-to-extract/m-p/544747#M90870</link>
      <description>&lt;P&gt;Hello Dear Splunkers &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;Recently we got reported issue when our indexers are reporting multiple issues with timestamp extraction. I found out that one log file (with dedicated sourcetype) has multiple different formats of time. Therefore we are not able determine correct configuration for sourcetype iin props.conf&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Beginning of those events look like this:&lt;BR /&gt;1.&amp;nbsp;&lt;SPAN class="h"&gt;2021-03-22T16:15:31.995&lt;/SPAN&gt;&lt;SPAN&gt;+0800&lt;/SPAN&gt;&lt;BR /&gt;2.&amp;nbsp;&lt;SPAN&gt;[DEBUG] &lt;/SPAN&gt;&lt;SPAN class="h"&gt;2021-03-22 16:15:32.075&lt;/SPAN&gt;&lt;BR /&gt;3.&amp;nbsp;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class="t"&gt;2021-03-22T02:15:29.217&lt;/SPAN&gt; &lt;SPAN class="t"&gt;CST&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;Its input from *.stdout log file therefore there is a lot of different types of events.&lt;BR /&gt;I would like to skip letter "T" in time format definition but sadly I did not find anything that can help us.&lt;BR /&gt;Anybody dealt with situation like this?&lt;BR /&gt;Many thanks&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Denis&amp;nbsp;&amp;nbsp;&lt;BR /&gt;The biggest problem seems to be in letter "T".&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 10:13:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Multiple-time-formats-in-one-sourcetype-failed-to-extract/m-p/544747#M90870</guid>
      <dc:creator>Denis_B</dc:creator>
      <dc:date>2021-03-22T10:13:14Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple time formats in one sourcetype - failed to extract timestamp</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Multiple-time-formats-in-one-sourcetype-failed-to-extract/m-p/544748#M90871</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/229297"&gt;@Denis_B&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;You have to define the timestamp format and prefix in your sourcetype when you have:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;events in multiple rows, so you need the timestamp to define the event break,&lt;/LI&gt;&lt;LI&gt;timestamps in european format (dd/mm/yyyy), because Splunk by default uses the american standard (mm/dd/yyyy),&lt;/LI&gt;&lt;LI&gt;there are more than one timestamp in the same row and the correct one isn't the first, so Splunk takes as timestamp the first that finds.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;If you haven't one of the above conditions (as it seems by your samples), you could use the auto option in timestamp definition so Splunk adapts the parsing format to the timestamp format that it finds.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 10:30:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Multiple-time-formats-in-one-sourcetype-failed-to-extract/m-p/544748#M90871</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2021-03-22T10:30:12Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple time formats in one sourcetype - failed to extract timestamp</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Multiple-time-formats-in-one-sourcetype-failed-to-extract/m-p/544760#M90873</link>
      <description>&lt;P&gt;You may achieve this using datetime.xml, have a look at my old answer post &lt;A href="https://community.splunk.com/t5/Getting-Data-In/How-can-we-set-TIME-FORMAT-in-props-conf-where-the-milliseconds/m-p/424929" target="_blank"&gt;https://community.splunk.com/t5/Getting-Data-In/How-can-we-set-TIME-FORMAT-in-props-conf-where-the-milliseconds/m-p/424929&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 12:35:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Multiple-time-formats-in-one-sourcetype-failed-to-extract/m-p/544760#M90873</guid>
      <dc:creator>harsmarvania57</dc:creator>
      <dc:date>2021-03-22T12:35:52Z</dc:date>
    </item>
  </channel>
</rss>

