<?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 to seperate different index and sourcetype? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82710#M17151</link>
    <description>&lt;P&gt;I know how to set index using Splunk web interface.&lt;BR /&gt;
Also, I know how to receive the data from UDF514.&lt;/P&gt;

&lt;P&gt;But I don't know about the meaning of "Format" and "$0"   and "metadata" "_metadata" even I check the transforms.conf.sample file.&lt;BR /&gt;
1 So anyone can explain it ? &lt;BR /&gt;
2 Also, if possible , correct my configuration if anything is wrong!!&lt;BR /&gt;
3 Should I assign different sourcetype for F5, cisco, fortigate? How? Which file?&lt;BR /&gt;
Thank you very much!&lt;/P&gt;

&lt;P&gt;Here is my configuration&lt;BR /&gt;
props.conf&lt;BR /&gt;
[F5_syslog]&lt;BR /&gt;
TRANSFORMS-F5=asm_log&lt;/P&gt;

&lt;P&gt;[cisco-router_syslog]&lt;BR /&gt;
TRANSFORM-cisco=cisco-router&lt;/P&gt;

&lt;P&gt;[fortigate_syslog]&lt;BR /&gt;
TRANSFORM-forti=fortigate&lt;/P&gt;

&lt;P&gt;transforms.conf&lt;BR /&gt;
[asm_log]&lt;BR /&gt;
REGEX = 10.10.10.10|10.10.10.11&lt;BR /&gt;
DEST_KEY = _MetaData:Index&lt;BR /&gt;
FORMAT = F5_ASM&lt;/P&gt;

&lt;P&gt;[cisco-router]&lt;BR /&gt;
REGEX = 172.16.16.*&lt;BR /&gt;
DEST_KEY = _MetaData:Index&lt;BR /&gt;
FORMAT = cisco_log&lt;/P&gt;

&lt;P&gt;[Fortigate]&lt;BR /&gt;
REGEX = 10.10.10.20|10.10.10.21&lt;BR /&gt;
DEST_KEY = _MetaData:Index&lt;BR /&gt;
FORMAT = Forti_log&lt;/P&gt;

&lt;P&gt;For my 2nd question &lt;BR /&gt;
at windows server (with forwarder):&lt;BR /&gt;
I do nothing just using windows-ta-app. &lt;/P&gt;

&lt;P&gt;at unix server(with forwarder):&lt;BR /&gt;
[monitor:///var/log]&lt;BR /&gt;
sourcetype=unix&lt;BR /&gt;
index=unix&lt;/P&gt;</description>
    <pubDate>Mon, 28 Sep 2020 14:54:17 GMT</pubDate>
    <dc:creator>johnwyane</dc:creator>
    <dc:date>2020-09-28T14:54:17Z</dc:date>
    <item>
      <title>How to seperate different index and sourcetype?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82708#M17149</link>
      <description>&lt;P&gt;HI,&lt;BR /&gt;
  I have one Splunk server. I would like to receive data from some servers and network devices.&lt;BR /&gt;
1 I would send F5  (10.10.10.10 and 10.10.10.11) log and cisco router (172.16.16.10 etc.) and firewall Fortigate (10.10.10.20 &amp;amp; 10.10.10.21)log to my Splunk server by UDP 514.&lt;BR /&gt;
2 Also, I would use light universal forwarder to send data of windows &amp;amp; Unix servers to my splunk server.&lt;BR /&gt;
However, I would like to use different sourcetype and index to identify the different devices.&lt;BR /&gt;
For example, sourcetype=win_AD index=win_AD ,  sourcetype=sun index=sun , sourcetype=asm index=asm , sourcetype=cisco index=cisco , sourcetype=forti index=forti&lt;/P&gt;

&lt;P&gt;After I study some manuals and some of splunkbase answers. I know I have to modified props.conf and transforms.conf .&lt;BR /&gt;
1 How to configure above two files?&lt;BR /&gt;
2 How to setup unix and window AD with universal forwarder configured file?&lt;BR /&gt;
Any one could give me a complete method to set it up?&lt;BR /&gt;
Thank you very much!&lt;/P&gt;

&lt;P&gt;Anthony&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 14:53:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82708#M17149</guid>
      <dc:creator>johnwyane</dc:creator>
      <dc:date>2020-09-28T14:53:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to seperate different index and sourcetype?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82709#M17150</link>
      <description>&lt;P&gt;What information are you missing from the docs/splunkbase answers you found? We can help, but we can't do all the work for you - you need to understand the mechanisms before you can implement this.&lt;/P&gt;</description>
      <pubDate>Fri, 04 Oct 2013 09:12:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82709#M17150</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2013-10-04T09:12:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to seperate different index and sourcetype?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82710#M17151</link>
      <description>&lt;P&gt;I know how to set index using Splunk web interface.&lt;BR /&gt;
Also, I know how to receive the data from UDF514.&lt;/P&gt;

&lt;P&gt;But I don't know about the meaning of "Format" and "$0"   and "metadata" "_metadata" even I check the transforms.conf.sample file.&lt;BR /&gt;
1 So anyone can explain it ? &lt;BR /&gt;
2 Also, if possible , correct my configuration if anything is wrong!!&lt;BR /&gt;
3 Should I assign different sourcetype for F5, cisco, fortigate? How? Which file?&lt;BR /&gt;
Thank you very much!&lt;/P&gt;

&lt;P&gt;Here is my configuration&lt;BR /&gt;
props.conf&lt;BR /&gt;
[F5_syslog]&lt;BR /&gt;
TRANSFORMS-F5=asm_log&lt;/P&gt;

&lt;P&gt;[cisco-router_syslog]&lt;BR /&gt;
TRANSFORM-cisco=cisco-router&lt;/P&gt;

&lt;P&gt;[fortigate_syslog]&lt;BR /&gt;
TRANSFORM-forti=fortigate&lt;/P&gt;

&lt;P&gt;transforms.conf&lt;BR /&gt;
[asm_log]&lt;BR /&gt;
REGEX = 10.10.10.10|10.10.10.11&lt;BR /&gt;
DEST_KEY = _MetaData:Index&lt;BR /&gt;
FORMAT = F5_ASM&lt;/P&gt;

&lt;P&gt;[cisco-router]&lt;BR /&gt;
REGEX = 172.16.16.*&lt;BR /&gt;
DEST_KEY = _MetaData:Index&lt;BR /&gt;
FORMAT = cisco_log&lt;/P&gt;

&lt;P&gt;[Fortigate]&lt;BR /&gt;
REGEX = 10.10.10.20|10.10.10.21&lt;BR /&gt;
DEST_KEY = _MetaData:Index&lt;BR /&gt;
FORMAT = Forti_log&lt;/P&gt;

&lt;P&gt;For my 2nd question &lt;BR /&gt;
at windows server (with forwarder):&lt;BR /&gt;
I do nothing just using windows-ta-app. &lt;/P&gt;

&lt;P&gt;at unix server(with forwarder):&lt;BR /&gt;
[monitor:///var/log]&lt;BR /&gt;
sourcetype=unix&lt;BR /&gt;
index=unix&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 14:54:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82710#M17151</guid>
      <dc:creator>johnwyane</dc:creator>
      <dc:date>2020-09-28T14:54:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to seperate different index and sourcetype?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82711#M17152</link>
      <description>&lt;P&gt;You'll need to ensure that the incoming data on port 514 will be separated into different sourcetypes before this configuration will work (since you are making transforms based on sourcetypes, right).&lt;/P&gt;

&lt;P&gt;Also, quite separately, your REGEXes might be a bit too unspecific, since they will match on the existence of a string (in your case ip-addresses) regardless of &lt;EM&gt;where&lt;/EM&gt; they appear in the message. Perhaps the addition of a &lt;CODE&gt;SOURCE_KEY&lt;/CODE&gt; attribute in your transforms can help you with that (i.e. ensure that the REGEX is matching on the &lt;CODE&gt;host&lt;/CODE&gt; and not on the whole &lt;CODE&gt;_raw&lt;/CODE&gt; event.&lt;/P&gt;</description>
      <pubDate>Sat, 05 Oct 2013 10:32:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-seperate-different-index-and-sourcetype/m-p/82711#M17152</guid>
      <dc:creator>kristian_kolb</dc:creator>
      <dc:date>2013-10-05T10:32:30Z</dc:date>
    </item>
  </channel>
</rss>

