<?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 Troubles with creating a new source type in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142059#M29086</link>
    <description>&lt;P&gt;Hi there,&lt;/P&gt;

&lt;P&gt;I've been trying to create a new source type, but unfortunately - with no success.&lt;/P&gt;

&lt;P&gt;My data is uploaded from a CSV file (hold your horses, there's a small catch).&lt;BR /&gt;
&lt;STRONG&gt;I put all of the relevant files in a folder&lt;/STRONG&gt; (I use Windows) &lt;STRONG&gt;named&lt;/STRONG&gt; "C:\Users\USERNAME\Desktop\USERNAME...\packetLog" - I wish that Splunk will continually index new files in this folder.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Each line in the CSV files looks like this&lt;/STRONG&gt; (each field is separated by a semicolon):&lt;/P&gt;

&lt;P&gt;1375781456.56672;2013-08-06 12:30:56.056672;1;1;1;1;0x0;1514;1500;1480;0xc5f7;0x4000;58;6;TCP;0x4848;0x5250fa16;82.80.250.22;&lt;BR /&gt;
0xd4b30bc2;212.179.11.194;80;34212;0xa20f32aa;0x82f09e0a;0;0;0;0;1;0;0;0;54;0x9b4d0000;-1;-1;&lt;BR /&gt;
0x0;-1;0x0;0;0;0;0;0&lt;/P&gt;

&lt;P&gt;After reviewing some online documentations and examples, I created a new sourcetype in C:\Program Files\Splunk\etc\system\local\props.conf:&lt;/P&gt;

&lt;P&gt;[source::...\packetLog...]&lt;/P&gt;

&lt;P&gt;sourcetype = Analyzer_packets&lt;/P&gt;

&lt;P&gt;FIELD_DELIMITER = ";"&lt;/P&gt;

&lt;P&gt;FIELD_NAMES = "TIMESTAMP","TIMESTAMP_Friendly","PacketId","FlowId","pcap_ID",...(and so on for the other field names).&lt;/P&gt;

&lt;P&gt;As you can probably see, creating fields with Regex in this case is &lt;EM&gt;extremely&lt;/EM&gt; difficult, since more than one value has the same (or very similar) pattern.&lt;/P&gt;

&lt;P&gt;Your help will be greatly appreciated. If there's a need for additional info just say so.&lt;BR /&gt;
Thanks!&lt;/P&gt;</description>
    <pubDate>Thu, 14 Nov 2013 10:28:14 GMT</pubDate>
    <dc:creator>osherma</dc:creator>
    <dc:date>2013-11-14T10:28:14Z</dc:date>
    <item>
      <title>Troubles with creating a new source type</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142059#M29086</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;

&lt;P&gt;I've been trying to create a new source type, but unfortunately - with no success.&lt;/P&gt;

&lt;P&gt;My data is uploaded from a CSV file (hold your horses, there's a small catch).&lt;BR /&gt;
&lt;STRONG&gt;I put all of the relevant files in a folder&lt;/STRONG&gt; (I use Windows) &lt;STRONG&gt;named&lt;/STRONG&gt; "C:\Users\USERNAME\Desktop\USERNAME...\packetLog" - I wish that Splunk will continually index new files in this folder.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Each line in the CSV files looks like this&lt;/STRONG&gt; (each field is separated by a semicolon):&lt;/P&gt;

&lt;P&gt;1375781456.56672;2013-08-06 12:30:56.056672;1;1;1;1;0x0;1514;1500;1480;0xc5f7;0x4000;58;6;TCP;0x4848;0x5250fa16;82.80.250.22;&lt;BR /&gt;
0xd4b30bc2;212.179.11.194;80;34212;0xa20f32aa;0x82f09e0a;0;0;0;0;1;0;0;0;54;0x9b4d0000;-1;-1;&lt;BR /&gt;
0x0;-1;0x0;0;0;0;0;0&lt;/P&gt;

&lt;P&gt;After reviewing some online documentations and examples, I created a new sourcetype in C:\Program Files\Splunk\etc\system\local\props.conf:&lt;/P&gt;

&lt;P&gt;[source::...\packetLog...]&lt;/P&gt;

&lt;P&gt;sourcetype = Analyzer_packets&lt;/P&gt;

&lt;P&gt;FIELD_DELIMITER = ";"&lt;/P&gt;

&lt;P&gt;FIELD_NAMES = "TIMESTAMP","TIMESTAMP_Friendly","PacketId","FlowId","pcap_ID",...(and so on for the other field names).&lt;/P&gt;

&lt;P&gt;As you can probably see, creating fields with Regex in this case is &lt;EM&gt;extremely&lt;/EM&gt; difficult, since more than one value has the same (or very similar) pattern.&lt;/P&gt;

&lt;P&gt;Your help will be greatly appreciated. If there's a need for additional info just say so.&lt;BR /&gt;
Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2013 10:28:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142059#M29086</guid>
      <dc:creator>osherma</dc:creator>
      <dc:date>2013-11-14T10:28:14Z</dc:date>
    </item>
    <item>
      <title>Re: Troubles with creating a new source type</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142060#M29087</link>
      <description>&lt;P&gt;(For some reason I can't edit my question, so here's some more info:)&lt;/P&gt;

&lt;P&gt;the fields extraction does not work at all:  Splunk doesn't recognize the files from the specific folder as a different sourcetype, and even worse - it doesn't extract the fields even when I apply the source type manually.&lt;BR /&gt;
First I had tried to change props.conf file with a text editor (but it didn't appear on the sources list in Splunk UI) and then I created the new sourcetype through the UI itself. &lt;/P&gt;

&lt;P&gt;The name of the folder is C:\Users\USERNAME\Desktop\USERNAME...packetLog\"&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2013 10:54:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142060#M29087</guid>
      <dc:creator>osherma</dc:creator>
      <dc:date>2013-11-14T10:54:03Z</dc:date>
    </item>
    <item>
      <title>Re: Troubles with creating a new source type</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142061#M29088</link>
      <description>&lt;P&gt;A restart is required if you make any changes to .conf file directly. Hope you are doing that.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2013 12:44:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142061#M29088</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2013-11-14T12:44:44Z</dc:date>
    </item>
    <item>
      <title>Re: Troubles with creating a new source type</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142062#M29089</link>
      <description>&lt;P&gt;I did restart Splunk, but it didn't change anything.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2013 14:25:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142062#M29089</guid>
      <dc:creator>osherma</dc:creator>
      <dc:date>2013-11-14T14:25:51Z</dc:date>
    </item>
    <item>
      <title>Re: Troubles with creating a new source type</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142063#M29090</link>
      <description>&lt;P&gt;Hi oshema,&lt;/P&gt;

&lt;P&gt;Try this:&lt;/P&gt;

&lt;P&gt;Instead FIELD_DELIMITER = ";" use DELIMS = ";"&lt;BR /&gt;
Instead FIELD_NAMES use FIELDS = "field1","field2","field3"&lt;/P&gt;

&lt;P&gt;Stop e Start Splunk.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 15:28:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Troubles-with-creating-a-new-source-type/m-p/142063#M29090</guid>
      <dc:creator>rafamss</dc:creator>
      <dc:date>2020-09-28T15:28:56Z</dc:date>
    </item>
  </channel>
</rss>

