<?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: One source to two indexes in Deployment Architecture</title>
    <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407249#M20352</link>
    <description>&lt;P&gt;Hi @m_efremov,&lt;/P&gt;

&lt;P&gt;As far as I know you can't clone data to 2 indexes on same indexer cluster with data flow from UF -&amp;gt; Indexer directly but there are ugly way to achieve this as given below &lt;STRONG&gt;but it will double your license usage for that source.&lt;/STRONG&gt;.&lt;/P&gt;

&lt;P&gt;Here I am assuming as of now you are sending data directly from Universal Forwarder to Indexer Cluster and Heavy Forwarder is sending data to same Indexer Cluster.&lt;BR /&gt;
With below approach data flow will be like&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;UF -&amp;gt; Indexer Cluster (Index = ABC)
        Heavy Forwarder                       -&amp;gt; Indexer Cluster(Index = XYZ)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;UL&gt;
&lt;LI&gt;On Universal Forwarder you can do below configuration to send same data (Cloning of data) to Indexer and Heavy Forwarder&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;inputs.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[monitor:///tmp/]
_TCP_ROUTING = indexers, heavyforwarder
whitelist = mycustom\.log
index = ABC
sourcetype = mysourcetype
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;outputs.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[tcpout]
defaultGroup = indexers

[tcpout:indexers]
server = indexer1:port, indexer2:port

[tcpout:heavyforwarder]
server = hfw:port
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;UL&gt;
&lt;LI&gt;Configuration require on heavy forwarder (Assuming Heavy Forwarder is already sending data to Indexer Cluster)&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;props.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[mysourcetype]
TRANSFORMS-rouindex = routing_to_index
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[routing_to_index]
REGEX = .
DEST_KEY = _MetaData:Index
FORMAT = XYZ
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 04 Oct 2018 10:21:34 GMT</pubDate>
    <dc:creator>harsmarvania57</dc:creator>
    <dc:date>2018-10-04T10:21:34Z</dc:date>
    <item>
      <title>One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407247#M20350</link>
      <description>&lt;P&gt;We created two indexes at our indexer cluster. Now we need to send the same data to both of them (clear data to the first one and transformed to another one, but from one source, from one univarsal forwarder). How can we implement it? On which host: universal forwarder, heavy forwarder, indexer?&lt;/P&gt;</description>
      <pubDate>Thu, 04 Oct 2018 09:11:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407247#M20350</guid>
      <dc:creator>m_efremov</dc:creator>
      <dc:date>2018-10-04T09:11:27Z</dc:date>
    </item>
    <item>
      <title>Re: One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407248#M20351</link>
      <description>&lt;P&gt;what i understand from your question is, &lt;CODE&gt;you want to send a single log file to two indexes&lt;/CODE&gt;.&lt;/P&gt;

&lt;P&gt;from @woodcock 's answer on this post - &lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/567223/how-to-send-same-data-source-to-two-or-multiple-in-1.html"&gt;https://answers.splunk.com/answers/567223/how-to-send-same-data-source-to-two-or-multiple-in-1.html&lt;/A&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[monitor://D:\test\test1.log]
 sourcetype = test
 index = index1

 [monitor://D:\linktotest\test1.log]
 sourcetype = test
 index = index2
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The create s symbolic link from linktotest to test:&lt;/P&gt;</description>
      <pubDate>Thu, 04 Oct 2018 09:46:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407248#M20351</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2018-10-04T09:46:51Z</dc:date>
    </item>
    <item>
      <title>Re: One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407249#M20352</link>
      <description>&lt;P&gt;Hi @m_efremov,&lt;/P&gt;

&lt;P&gt;As far as I know you can't clone data to 2 indexes on same indexer cluster with data flow from UF -&amp;gt; Indexer directly but there are ugly way to achieve this as given below &lt;STRONG&gt;but it will double your license usage for that source.&lt;/STRONG&gt;.&lt;/P&gt;

&lt;P&gt;Here I am assuming as of now you are sending data directly from Universal Forwarder to Indexer Cluster and Heavy Forwarder is sending data to same Indexer Cluster.&lt;BR /&gt;
With below approach data flow will be like&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;UF -&amp;gt; Indexer Cluster (Index = ABC)
        Heavy Forwarder                       -&amp;gt; Indexer Cluster(Index = XYZ)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;UL&gt;
&lt;LI&gt;On Universal Forwarder you can do below configuration to send same data (Cloning of data) to Indexer and Heavy Forwarder&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;inputs.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[monitor:///tmp/]
_TCP_ROUTING = indexers, heavyforwarder
whitelist = mycustom\.log
index = ABC
sourcetype = mysourcetype
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;outputs.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[tcpout]
defaultGroup = indexers

[tcpout:indexers]
server = indexer1:port, indexer2:port

[tcpout:heavyforwarder]
server = hfw:port
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;UL&gt;
&lt;LI&gt;Configuration require on heavy forwarder (Assuming Heavy Forwarder is already sending data to Indexer Cluster)&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;props.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[mysourcetype]
TRANSFORMS-rouindex = routing_to_index
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[routing_to_index]
REGEX = .
DEST_KEY = _MetaData:Index
FORMAT = XYZ
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 04 Oct 2018 10:21:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407249#M20352</guid>
      <dc:creator>harsmarvania57</dc:creator>
      <dc:date>2018-10-04T10:21:34Z</dc:date>
    </item>
    <item>
      <title>Re: One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407250#M20353</link>
      <description>&lt;P&gt;Thank you, &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/163905"&gt;@harsmarvania57&lt;/a&gt; , it seems to be a workable solution. My transform.conf also contains "CLONE_SOURCETYPE", but all other options are same.&lt;BR /&gt;
    [routing_to_new_index]&lt;BR /&gt;
    REGEX = .&lt;BR /&gt;
    CLONE_SOURCETYPE = my_new_sourcetype&lt;BR /&gt;
    FORMAT = my_new_index&lt;BR /&gt;
    DEST_KEY = _MetaData:Index&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 21:33:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407250#M20353</guid>
      <dc:creator>m_efremov</dc:creator>
      <dc:date>2020-09-29T21:33:40Z</dc:date>
    </item>
    <item>
      <title>Re: One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407251#M20354</link>
      <description>&lt;P&gt;I have converted my comment to answer, if it really helps you then you can accept it. Can I ask you why you want &lt;CODE&gt;CLONE_SOURCETYPE&lt;/CODE&gt; ?&lt;/P&gt;</description>
      <pubDate>Fri, 05 Oct 2018 12:28:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407251#M20354</guid>
      <dc:creator>harsmarvania57</dc:creator>
      <dc:date>2018-10-05T12:28:09Z</dc:date>
    </item>
    <item>
      <title>Re: One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407252#M20355</link>
      <description>&lt;P&gt;We can't do it at most of our application servers. Some of them not under our control, some of them are working under MS Windows etc. Thank your for answer but it is not general solution.&lt;/P&gt;</description>
      <pubDate>Fri, 05 Oct 2018 13:25:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407252#M20355</guid>
      <dc:creator>m_efremov</dc:creator>
      <dc:date>2018-10-05T13:25:33Z</dc:date>
    </item>
    <item>
      <title>Re: One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407253#M20356</link>
      <description>&lt;P&gt;I use CLONE_SOURCETYPE for assigning different sourcetype name (not only index) for my new data flow. It is because I want do different transformations for old and new data (may be at indexers side, in their props.conf and transforms.conf). Also i was collect separate statistics about old and new sourcetypes (one of them has transformed events)&lt;/P&gt;</description>
      <pubDate>Fri, 05 Oct 2018 13:31:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407253#M20356</guid>
      <dc:creator>m_efremov</dc:creator>
      <dc:date>2018-10-05T13:31:10Z</dc:date>
    </item>
    <item>
      <title>Re: One source to two indexes</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407254#M20357</link>
      <description>&lt;P&gt;For renaming of sourcetype and routing data to another index, can you please try below configuration on Heavy Forwarder?&lt;/P&gt;

&lt;P&gt;props.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[mysourcetype]
TRANSFORMS-rouindex = rename_sourcetype, routing_to_new_index
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[rename_sourcetype]
REGEX = .
DEST_KEY = MetaData:Sourcetype
FORMAT = sourcetype::new_sourcetype

[routing_to_new_index]
SOURCE_KEY = MetaData:Sourcetype
DEST_KEY = _MetaData:Index
REGEX = new_sourcetype
FORMAT = XYZ
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 05 Oct 2018 13:40:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/One-source-to-two-indexes/m-p/407254#M20357</guid>
      <dc:creator>harsmarvania57</dc:creator>
      <dc:date>2018-10-05T13:40:30Z</dc:date>
    </item>
  </channel>
</rss>

