<?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: Optimizing custom log formats in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84357#M17530</link>
    <description>&lt;P&gt;SOLVED: I ended up setting the TIME_FORMAT. Thanks&lt;/P&gt;</description>
    <pubDate>Tue, 19 Apr 2011 23:43:56 GMT</pubDate>
    <dc:creator>travispowell</dc:creator>
    <dc:date>2011-04-19T23:43:56Z</dc:date>
    <item>
      <title>Optimizing custom log formats</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84354#M17527</link>
      <description>&lt;P&gt;I read a post on the site describing how an optimum custom log format for Splunk would take the form:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;timestamp&amp;gt; key=val key=val key=val key=val
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;...and I tried to build a log formatter for our in-house software that would write logs like this. I'm trying out Splunk, and trying to figure out why it doesn't pick up the timestamps for what they are. Here's a single log entry (the first number is a UNIX timestamp):&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;1303115585 SESSION_KEY=56c2964bce6b36da9e895c5be963584a REMOTE_ADDRESS=65.13.25.203 CANISTER_LSSN=LSSN_20110418_MASTER.dat CANISTER_SESSION_ID=153051 SID=7B019FB669961069023EADEB66C4E2BE UID=6C6838A20A1E100A01139E8210F7048E VID= CANISTER_SERVER=MASTER:19000 DURATION=103 HCOUNT=2 HTTP_USER_AGENT=Windows-RSS-Platform/2.0_(MSIE_8.0;_Windows_NT_5.1) EXTRACTID=1303156352 LINK=http:\/\/MASTER:19000/Session.rfx?canName%3DCANISTER.dbs\LSSN_20110418_MASTER.dat&amp;amp;sessionId%3D153051
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I'm wondering if the link at the end if causing me grief, but I even encoded the '=' and replaced the spaces in the HTTP_USER_AGENT field with underscores.&lt;/P&gt;

&lt;P&gt;So am I right to assume that I have to teach it how to read my dates with the &lt;CODE&gt;&amp;gt;splunk train&lt;/CODE&gt; command? Does Splunk not auto-extract UNIX timestamps?&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2011 17:39:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84354#M17527</guid>
      <dc:creator>travispowell</dc:creator>
      <dc:date>2011-04-19T17:39:17Z</dc:date>
    </item>
    <item>
      <title>Re: Optimizing custom log formats</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84355#M17528</link>
      <description>&lt;P&gt;There was a bug related to auto-detecting an epoch time format, fixed in 4.2.1.  You can see a set of workarounds at &lt;A href="http://www.splunk.com/base/Documentation/4.2/ReleaseNotes/Knownissues"&gt;http://www.splunk.com/base/Documentation/4.2/ReleaseNotes/Knownissues&lt;/A&gt;. My personal preference is to explicitly set &lt;CODE&gt;TIME_FORMAT&lt;/CODE&gt; for my sourcetypes so there is no guessing as to how the time is parsed.&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2011 19:04:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84355#M17528</guid>
      <dc:creator>dwaddle</dc:creator>
      <dc:date>2011-04-19T19:04:18Z</dc:date>
    </item>
    <item>
      <title>Re: Optimizing custom log formats</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84356#M17529</link>
      <description>&lt;P&gt;Guess that's what I'll have to do. I don't think it's entirely fixed.&lt;BR /&gt;
Thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2011 19:14:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84356#M17529</guid>
      <dc:creator>travispowell</dc:creator>
      <dc:date>2011-04-19T19:14:46Z</dc:date>
    </item>
    <item>
      <title>Re: Optimizing custom log formats</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84357#M17530</link>
      <description>&lt;P&gt;SOLVED: I ended up setting the TIME_FORMAT. Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2011 23:43:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Optimizing-custom-log-formats/m-p/84357#M17530</guid>
      <dc:creator>travispowell</dc:creator>
      <dc:date>2011-04-19T23:43:56Z</dc:date>
    </item>
  </channel>
</rss>

