<?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 Route index data based on source in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Route-index-data-based-on-source/m-p/688917#M114690</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Is it possible using props.conf and transforms.conf to route some data on an index based on the source field?&lt;/P&gt;&lt;P&gt;Let's say index1 contains a lot of sources, in some sources it contains certain words in the path for example&lt;/P&gt;&lt;P&gt;(source="*dev-ksm*" OR source="*int-ksm*" OR source="*qa-ksm*" OR source="*amq-*-ksm*")&lt;/P&gt;&lt;P&gt;For this scenario I'd like to route events that their source contains the above matching sources to an index2&lt;/P&gt;&lt;P&gt;Was thinking in something like this:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;props.conf&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[index::current_index]
TRANSFORMS-routing=filter-to-new_index&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;transforms.conf&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[filter-to-new_index]
DEST_KEY = _MetaData:Index 
SOURCE_KEY = MetaData:Source 
REGEX = (?i)(.*dev-ksm.*|.*int-ksm.*|.*qa-ksm.*|.*amq-.*-ksm.*)
FORMAT = new_index&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does not seem to be currently working. Hence the question if its possible to do something like this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 28 May 2024 22:11:43 GMT</pubDate>
    <dc:creator>rreatiga</dc:creator>
    <dc:date>2024-05-28T22:11:43Z</dc:date>
    <item>
      <title>Route index data based on source</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Route-index-data-based-on-source/m-p/688917#M114690</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Is it possible using props.conf and transforms.conf to route some data on an index based on the source field?&lt;/P&gt;&lt;P&gt;Let's say index1 contains a lot of sources, in some sources it contains certain words in the path for example&lt;/P&gt;&lt;P&gt;(source="*dev-ksm*" OR source="*int-ksm*" OR source="*qa-ksm*" OR source="*amq-*-ksm*")&lt;/P&gt;&lt;P&gt;For this scenario I'd like to route events that their source contains the above matching sources to an index2&lt;/P&gt;&lt;P&gt;Was thinking in something like this:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;props.conf&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[index::current_index]
TRANSFORMS-routing=filter-to-new_index&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;transforms.conf&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[filter-to-new_index]
DEST_KEY = _MetaData:Index 
SOURCE_KEY = MetaData:Source 
REGEX = (?i)(.*dev-ksm.*|.*int-ksm.*|.*qa-ksm.*|.*amq-.*-ksm.*)
FORMAT = new_index&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does not seem to be currently working. Hence the question if its possible to do something like this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 May 2024 22:11:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Route-index-data-based-on-source/m-p/688917#M114690</guid>
      <dc:creator>rreatiga</dc:creator>
      <dc:date>2024-05-28T22:11:43Z</dc:date>
    </item>
    <item>
      <title>Re: Route index data based on source</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Route-index-data-based-on-source/m-p/688948#M114693</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/267313"&gt;@rreatiga&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;in the header of the props.conf stanza, you cannot use "index::current_index" but only sourcetype or source or host fields.&lt;/P&gt;&lt;P&gt;for source and host, you can also use jolly char, something like this:&lt;/P&gt;&lt;P&gt;props.conf&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[source::*dev-ksm*]
TRANSFORMS-routing=filter-to-new_index

[source::*int-ksm*]
TRANSFORMS-routing=filter-to-new_index

[source::*qa-ksm*]
TRANSFORMS-routing=filter-to-new_index

[source::*amq-*-ksm*]
TRANSFORMS-routing=filter-to-new_index&lt;/LI-CODE&gt;&lt;P&gt;transorms.conf&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[filter-to-new_index]
DEST_KEY = _MetaData:Index 
REGEX = .
FORMAT = new_index&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2024 05:17:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Route-index-data-based-on-source/m-p/688948#M114693</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2024-05-29T05:17:16Z</dc:date>
    </item>
  </channel>
</rss>

