<?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: Problem: Unable to send cooked data to two different Indexer ports in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230925#M44959</link>
    <description>&lt;P&gt;Its not really possible to do this at the indexer side. Basically Splunk isnt able to change the meta data on multiple listening ports since it doesnt track which input port the data comes in on.&lt;/P&gt;</description>
    <pubDate>Wed, 05 Oct 2016 06:16:44 GMT</pubDate>
    <dc:creator>esix_splunk</dc:creator>
    <dc:date>2016-10-05T06:16:44Z</dc:date>
    <item>
      <title>Problem: Unable to send cooked data to two different Indexer ports</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230922#M44956</link>
      <description>&lt;P&gt;Hello Experts,&lt;/P&gt;

&lt;P&gt;I have an issue where I am unable to send cooked data to two different Indexer ports.&lt;/P&gt;

&lt;P&gt;My flow of traffic is UF &amp;gt; HF &amp;gt; IDX &lt;/P&gt;

&lt;P&gt;UF IP:  a.a.a.a&lt;BR /&gt;
HF IP:  y.y.y.y&lt;BR /&gt;
IDX IP:  x.x.x.x&lt;/P&gt;

&lt;P&gt;1)  Universal Forwarder is monitoring more than one input with different sourcetypes.&lt;BR /&gt;
2)  My Indexer is listening on TCP 9997 and TCP 9996 (Same Indexer is listening on both the ports)&lt;BR /&gt;
3)  I want the data with sourcetype ABC to hit TCP 9996 and all other data to hit TCP 9997 on the Indexer.&lt;BR /&gt;
4)  When hitting TCP 9996, the index should change to pqr index but while hitting TCP 9997 the index should remain the same as mentioned in the monitor stanza in UF&lt;/P&gt;

&lt;P&gt;My configuration is below:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;UF config&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;inputs.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;[monitor:///xyz/urgent]&lt;BR /&gt;
index= my_index&lt;BR /&gt;
sourcetype=ABC&lt;BR /&gt;
disabled=false&lt;/P&gt;

&lt;P&gt;[monitor:///var/important]&lt;BR /&gt;
index= my_index&lt;BR /&gt;
sourcetype=DEF&lt;BR /&gt;
disabled=false&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;outputs.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;[tcpout]&lt;BR /&gt;
useACK=true&lt;BR /&gt;
maxQueueSize=auto&lt;BR /&gt;
readTimeout=300&lt;/P&gt;

&lt;P&gt;[tcpout:HF]&lt;BR /&gt;
server = y.y.y.y:9997&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;HF config&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;inputs.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;[default]&lt;BR /&gt;
host = def.sdf.ppp&lt;/P&gt;

&lt;P&gt;[splunktcp://9997]&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;props.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;[ABC]&lt;BR /&gt;
TRANSFORMS-routing = route_data&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;transforms.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;[route_data]&lt;BR /&gt;
REGEX = .&lt;BR /&gt;
DEST_KEY = _TCP_ROUTING&lt;BR /&gt;
FORMAT = urgent&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;outputs.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;[tcpout]&lt;BR /&gt;
defaultGroup = important&lt;BR /&gt;
maxQueueSize = 50MB&lt;BR /&gt;
useACK = true&lt;/P&gt;

&lt;P&gt;[tcpout:important]&lt;BR /&gt;
server = x.x.x.x:9997&lt;/P&gt;

&lt;P&gt;[tcpout:urgent]&lt;BR /&gt;
server = x.x.x.x:9996&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Indexer config&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;inputs.conf&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;[default]&lt;BR /&gt;
host = abcdef.xyz.ppp&lt;/P&gt;

&lt;P&gt;[splunktcp://9997]&lt;/P&gt;

&lt;P&gt;[splunktcp://9996]&lt;BR /&gt;
index = pqr&lt;/P&gt;

&lt;P&gt;This is not working for me. The sourcetype ABC is still sending data on TCP 9997 and not changing the index.&lt;/P&gt;

&lt;P&gt;Have I missed something? is there anything wrong with the config?&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 11:17:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230922#M44956</guid>
      <dc:creator>splunk_kk</dc:creator>
      <dc:date>2020-09-29T11:17:07Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Unable to send cooked data to two different Indexer ports</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230923#M44957</link>
      <description>&lt;P&gt;In your inputs.conf on the indexers, for splunktcp, index = is not a valid option.&lt;/P&gt;

&lt;P&gt;You cannot do it this way. You would need to rewrite the index metadata for the sourcetype on your HF by adding another transform and change the index metadata.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Oct 2016 05:27:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230923#M44957</guid>
      <dc:creator>esix_splunk</dc:creator>
      <dc:date>2016-10-05T05:27:28Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Unable to send cooked data to two different Indexer ports</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230924#M44958</link>
      <description>&lt;P&gt;Thanks Esix, That worked for me.... &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; ok a quick question, If in case I need to send the data from sourcetype ABC to both the ports (9997 and 9996) and change the index when it hits 9996. will that be possible? if I change the index metadata at HF it will change the index for both the ports. &lt;/P&gt;

&lt;P&gt;Do I need to write props and transforms in Index for that to work? I doubt&lt;/P&gt;</description>
      <pubDate>Wed, 05 Oct 2016 06:09:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230924#M44958</guid>
      <dc:creator>splunk_kk</dc:creator>
      <dc:date>2016-10-05T06:09:07Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Unable to send cooked data to two different Indexer ports</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230925#M44959</link>
      <description>&lt;P&gt;Its not really possible to do this at the indexer side. Basically Splunk isnt able to change the meta data on multiple listening ports since it doesnt track which input port the data comes in on.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Oct 2016 06:16:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230925#M44959</guid>
      <dc:creator>esix_splunk</dc:creator>
      <dc:date>2016-10-05T06:16:44Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Unable to send cooked data to two different Indexer ports</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230926#M44960</link>
      <description>&lt;P&gt;Think about your issue, I think you would be better to approach this differently. Instead of trying to assign the index or priority based on the inbound SplunkTCP port, why dont you add metadata at the ingest time. Add a metadata field such as PRIORITY-HIGH, and then at the HF layer, filter that to a specific index and all other data to general indexes...&lt;/P&gt;

&lt;P&gt;See documentation here : &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.5.0/Data/Configureindex-timefieldextraction"&gt;http://docs.splunk.com/Documentation/Splunk/6.5.0/Data/Configureindex-timefieldextraction&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Note, this does add an indexed field, which does effect indexing performance. But this is a better approach then trying to work with multiple TCP inputs and trasnforms.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Oct 2016 06:28:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Unable-to-send-cooked-data-to-two-different-Indexer/m-p/230926#M44960</guid>
      <dc:creator>esix_splunk</dc:creator>
      <dc:date>2016-10-05T06:28:14Z</dc:date>
    </item>
  </channel>
</rss>

