<?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 do I configure Splunk to recognize the non-standard timestamp format in my log file? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181949#M36471</link>
    <description>&lt;P&gt;My apologies - I accidentally used a '$' instead of a '%' in my previous comment! It should have read...&lt;/P&gt;

&lt;P&gt;"I tried $Y//%m//%d %H/:%M/:%S Z in the 'Timestamp -&amp;gt; Advanced -&amp;gt; Timestamp Format' field"&lt;/P&gt;</description>
    <pubDate>Fri, 21 Aug 2015 08:04:05 GMT</pubDate>
    <dc:creator>markwymer</dc:creator>
    <dc:date>2015-08-21T08:04:05Z</dc:date>
    <item>
      <title>How do I configure Splunk to recognize the non-standard timestamp format in my log file?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181944#M36466</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;

&lt;P&gt;I'm trying to Upload a file/log using the 'Add Data' -&amp;gt; 'upload' in Splunk Web. Unfortunately, as per most of our logs, the input isn't in a structured format &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;An example event looks like:-&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;my_application : access_live_05_6021 : 2015//08//18 20/:33/:24 Z : SUCCESS : apps.baplc.com%2Ftravel%2Fcarsproxy%2Fpublic%2Fen
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;My, initial, problem is that I can't get Splunk to recognise the timestamp - &lt;CODE&gt;2015//08//18 20/:33/:24 Z&lt;/CODE&gt; - I tried &lt;CODE&gt;$Y//%m//%d $H/:$M/:%S Z&lt;/CODE&gt; in the 'Timestamp -&amp;gt; Advanced -&amp;gt; Timestamp Format' field, but it still couldn't detect the date field. I have a feeling that there is some kind of regex escape type stuff required, but ( I think ) I've tried everything except the correct solution!&lt;/P&gt;

&lt;P&gt;The second question - for an extra bonus point &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;  - is there an easy way in Splunk to change the &lt;CODE&gt;apps.baplc.com%2Ftravel%2Fgeneral%2Fpublic%2Fen&lt;/CODE&gt; to &lt;CODE&gt;apps.baplc.com/travel/general/public/en&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;Many thanks for any help,&lt;BR /&gt;
Mark.&lt;/P&gt;</description>
      <pubDate>Thu, 20 Aug 2015 15:21:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181944#M36466</guid>
      <dc:creator>markwymer</dc:creator>
      <dc:date>2015-08-20T15:21:49Z</dc:date>
    </item>
    <item>
      <title>Re: How do I configure Splunk to recognize the non-standard timestamp format in my log file?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181945#M36467</link>
      <description>&lt;P&gt;First off, are the dollar signs in your timestamp format typos or actually what you tried?  They should be percent signs. &lt;/P&gt;

&lt;P&gt;For the second part I think the urldecode function should work.  As an example&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| noop | stats count | eval blah="apps.baplc.com%2Ftravel%2Fgeneral%2Fpublic%2Fen"   | eval meh =urldecode(blah)
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 20 Aug 2015 16:15:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181945#M36467</guid>
      <dc:creator>maciep</dc:creator>
      <dc:date>2015-08-20T16:15:04Z</dc:date>
    </item>
    <item>
      <title>Re: How do I configure Splunk to recognize the non-standard timestamp format in my log file?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181946#M36468</link>
      <description>&lt;P&gt;In Splunk Web -&amp;gt; Data Preview, In Timestamps tab, use following&lt;/P&gt;

&lt;P&gt;1) Timestamp is always prefaced by a pattern   -  &lt;CODE&gt;^\s*\w+\s*:\s*\w+\s*:\s*&lt;/CODE&gt;&lt;BR /&gt;
2) Timestamp format (strptime)   -   &lt;CODE&gt;%Y//%m//%d %H/:%M/:%S&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Aug 2015 16:17:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181946#M36468</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2015-08-20T16:17:05Z</dc:date>
    </item>
    <item>
      <title>Re: How do I configure Splunk to recognize the non-standard timestamp format in my log file?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181947#M36469</link>
      <description>&lt;P&gt;Try this in the Timestamp Format box:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;%Y//%m//%d %H/:%M/:%S %Z
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;No escaping is necessary, unless you want to include the literal '%' character in your format string.  If it doesn't work, try specifying &lt;CODE&gt;:\s+&lt;/CODE&gt; as the time prefix.&lt;/P&gt;

&lt;P&gt;For your second question, consider added a sed command to your props.conf file:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[mysourcetype]
SEDCMD-slash = s/%2F/\//g
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 20 Aug 2015 16:30:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181947#M36469</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2015-08-20T16:30:59Z</dc:date>
    </item>
    <item>
      <title>Re: How do I configure Splunk to recognize the non-standard timestamp format in my log file?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181948#M36470</link>
      <description>&lt;P&gt;my apologies - yes the '$' were a typo&lt;/P&gt;</description>
      <pubDate>Fri, 21 Aug 2015 06:26:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181948#M36470</guid>
      <dc:creator>markwymer</dc:creator>
      <dc:date>2015-08-21T06:26:42Z</dc:date>
    </item>
    <item>
      <title>Re: How do I configure Splunk to recognize the non-standard timestamp format in my log file?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181949#M36471</link>
      <description>&lt;P&gt;My apologies - I accidentally used a '$' instead of a '%' in my previous comment! It should have read...&lt;/P&gt;

&lt;P&gt;"I tried $Y//%m//%d %H/:%M/:%S Z in the 'Timestamp -&amp;gt; Advanced -&amp;gt; Timestamp Format' field"&lt;/P&gt;</description>
      <pubDate>Fri, 21 Aug 2015 08:04:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-configure-Splunk-to-recognize-the-non-standard/m-p/181949#M36471</guid>
      <dc:creator>markwymer</dc:creator>
      <dc:date>2015-08-21T08:04:05Z</dc:date>
    </item>
  </channel>
</rss>

