<?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 tell a Splunk Universal Forwarder to not to monitor its own log files? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287423#M54892</link>
    <description>&lt;P&gt;Do you happen to be running the "Splunk Add-on for Unix and Linux" TA on the forwarder?&lt;BR /&gt;&lt;BR /&gt;
You may have to disable various monitor stanzas in that application's inputs.conf.&lt;/P&gt;</description>
    <pubDate>Sat, 24 Oct 2015 15:49:41 GMT</pubDate>
    <dc:creator>pickerin</dc:creator>
    <dc:date>2015-10-24T15:49:41Z</dc:date>
    <item>
      <title>How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287416#M54885</link>
      <description>&lt;P&gt;Hello Everyone,&lt;/P&gt;

&lt;P&gt;We are trying to monitor log files on a server using the Splunk universal forwarder. The logs directory (say  /logs/app3/Oct2015) is being monitored by Splunk forwarder.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;/opt/splunkforwarder/etc/system/local/inputs.conf :&lt;/STRONG&gt; &lt;BR /&gt;
&lt;EM&gt;Reference&lt;/EM&gt;: &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.3.0/Data/Monitorfilesanddirectorieswithinputs.conf"&gt;http://docs.splunk.com/Documentation/Splunk/6.3.0/Data/Monitorfilesanddirectorieswithinputs.conf&lt;/A&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[monitor:///logs/app3/Oct2015/]
    sourcetype = access_common
    ignoreOlderThan = 7d
    recurse = true
    _TCP_ROUTING = toLogAggregator
    blacklist = /opt/splunkforwarder/...

[blacklist:/opt/splunkforwarder/...]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This is my Output configuration -&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;/opt/splunkforwarder/etc/system/local/outputs.conf :&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;
&lt;EM&gt;Reference&lt;/EM&gt;:  &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.3.0/Forwarding/Configureforwarderswithoutputs.conf"&gt;http://docs.splunk.com/Documentation/Splunk/6.3.0/Forwarding/Configureforwarderswithoutputs.conf&lt;/A&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[tcpout]
defaultGroup = toBeIgnored

# This target group will redirect events to Log aggregator listening on TCP socket.
[tcpout:toLogAggregator]
server = 10.20.176.207:9997
sendCookedData = false

[tcpout:toBeIgnored]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;When I run the Splunk Universal Forwarder (v6.3), I am successfully able to monitor my logs directory, but Splunk is also sending me its own logs. I added a blacklist stanza to stop Splunk from monitoring and sending me its own logs, but no luck. My aggregator server is continuously receiving Splunk logs mixed with logs I am monitoring.&lt;/P&gt;

&lt;P&gt;I added a TCP output group to drain events by default and explicitly marked my monitored directory to route logs using a different TCP group, but that also didn't work. Still getting bombarded with Splunk logs.&lt;/P&gt;

&lt;P&gt;Does anyone knows, how to tell Splunk Forwarder to not to monitor itself but only monitor the directory I have requested for ?&lt;/P&gt;

&lt;P&gt;regards,&lt;/P&gt;

&lt;P&gt;-Vipul;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Oct 2015 23:26:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287416#M54885</guid>
      <dc:creator>VipulPathak</dc:creator>
      <dc:date>2015-10-22T23:26:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287417#M54886</link>
      <description>&lt;P&gt;First, why don't you want Splunk to send its internal logs? They are not charged against your license and the indexer will only keep about 500GB of the data at most. They can be &lt;EM&gt;very&lt;/EM&gt; useful when trying to monitor or debug your forwarder(s).&lt;/P&gt;

&lt;P&gt;Second, I don't know why your blacklist stanza doesn't work. I have never used one. The blacklist within your &lt;CODE&gt;[monitor:///logs/app3/Oct2015/]&lt;/CODE&gt; stanza definitely won't work.&lt;/P&gt;

&lt;P&gt;The setting on the forwarder that sends the internal logs is stored in &lt;CODE&gt;SPLUNK_HOME/etc/system/default/inputs.conf&lt;/CODE&gt; But &lt;STRONG&gt;don't&lt;/STRONG&gt; edit anything in the default directory. Override it in the local directory. &lt;/P&gt;

&lt;P&gt;To &lt;CODE&gt;SPLUNK_HOME/etc/system/local/inputs.conf&lt;/CODE&gt; on the forwarder, add the following &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[monitor://$SPLUNK_HOME/var/log/splunk]
disabled=true

[monitor://$SPLUNK_HOME/etc/splunk.version]
disabled=true
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Get rid of the blacklists. Restart the forwarder for the new settings to take effect.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Oct 2015 07:29:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287417#M54886</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-10-23T07:29:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287418#M54887</link>
      <description>&lt;P&gt;Thanks Iguinn for the response,&lt;/P&gt;

&lt;P&gt;Let me add more context here:&lt;BR /&gt;
On the other side of the network connection is a Java application reading from ServerSocket. We are collecting logs from different servers and posting them to HDFS for further hadoop based analysis. The data we are collecting from application servers, is RAW (uncooked) data.&lt;/P&gt;

&lt;P&gt;At this point, We are only interested in the application logs that is being watched.&lt;/P&gt;

&lt;P&gt;I added  the  &lt;CODE&gt;[monitor:///opt/splunkforwarder/var/log/splunk/]&lt;/CODE&gt; and &lt;CODE&gt;disabled=true&lt;/CODE&gt; under it in the local/inputs.conf file, but there is absolutely no effect on the behavior.&lt;/P&gt;

&lt;P&gt;I also tried to add multiple &lt;CODE&gt;[monitor:]&lt;/CODE&gt; with listing each file under var/log/splunk  in it, but still not effect.&lt;/P&gt;

&lt;P&gt;Please suggest.&lt;/P&gt;

&lt;P&gt;Thanks for your help.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Oct 2015 20:08:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287418#M54887</guid>
      <dc:creator>VipulPathak</dc:creator>
      <dc:date>2015-10-23T20:08:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287419#M54888</link>
      <description>&lt;P&gt;I would add the stanzas &lt;STRONG&gt;exactly&lt;/STRONG&gt; as I listed them. Not with the expanded path. Otherwise I am not sure that they will match for the override.&lt;/P&gt;

&lt;P&gt;So you are saying that you are using a Universal Forwarder, but it isn't forwarding to a Splunk indexer! Interesting.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Oct 2015 21:18:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287419#M54888</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-10-23T21:18:16Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287420#M54889</link>
      <description>&lt;P&gt;No, there is not Splunk indexer in the picture. I am forwarding to my own Java application that reads on a Socket and post the data to HDFS. So this is similar to forwarding to 3rd party system.&lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;(Splunk Forwarder) ====&amp;gt; (Java App&lt;BR /&gt;
Reading on Socket) =====&amp;gt; (Hadoop's&lt;BR /&gt;
HDFS)&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;Thats the reason, my output configuration is setting the attribute:   &lt;CODE&gt;sendCookedData = false&lt;/CODE&gt;.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Oct 2015 22:42:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287420#M54889</guid>
      <dc:creator>VipulPathak</dc:creator>
      <dc:date>2015-10-23T22:42:48Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287421#M54890</link>
      <description>&lt;P&gt;Cool. I get it.&lt;/P&gt;</description>
      <pubDate>Sat, 24 Oct 2015 01:54:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287421#M54890</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-10-24T01:54:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287422#M54891</link>
      <description>&lt;P&gt;Yeah, except that Splunk Universal Forwarder is continuing to send metrics and logs to the destination, mixing with other logs and I can't stop it  &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; &lt;/P&gt;

&lt;P&gt;Thanks for your support though  &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 24 Oct 2015 03:20:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287422#M54891</guid>
      <dc:creator>VipulPathak</dc:creator>
      <dc:date>2015-10-24T03:20:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287423#M54892</link>
      <description>&lt;P&gt;Do you happen to be running the "Splunk Add-on for Unix and Linux" TA on the forwarder?&lt;BR /&gt;&lt;BR /&gt;
You may have to disable various monitor stanzas in that application's inputs.conf.&lt;/P&gt;</description>
      <pubDate>Sat, 24 Oct 2015 15:49:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287423#M54892</guid>
      <dc:creator>pickerin</dc:creator>
      <dc:date>2015-10-24T15:49:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287424#M54893</link>
      <description>&lt;P&gt;Thanks for the pointer pickerin.&lt;/P&gt;

&lt;P&gt;I don't remember installing it, but since it is a shared environment with more than one admin users, I would definitely want to check for it. Where can I check for evidence of such plugin in action ? Any directory/config file etc. ?   I checked the &lt;STRONG&gt;apps&lt;/STRONG&gt; folder under  $SPLUNK_HOME/etc but didn't find any folder by name matching/similar to "Splunk Add-on for Unix and Linux".&lt;/P&gt;</description>
      <pubDate>Sun, 25 Oct 2015 19:39:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287424#M54893</guid>
      <dc:creator>VipulPathak</dc:creator>
      <dc:date>2015-10-25T19:39:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287425#M54894</link>
      <description>&lt;P&gt;File a support ticket: &lt;A href="http://www.splunk.com/en_us/support-and-services.html"&gt;http://www.splunk.com/en_us/support-and-services.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;This should have worked. Disabling the stanzas in etc/system/local/inputs.conf should have worked. As I understand it, the original blacklist stanza that you used should have worked.&lt;/P&gt;

&lt;P&gt;As a last option - edit the etc/system/defaults/inputs.conf file on the forwarder. Put "disabled=true" in each stanza as shown above. Restart the forwarder. While you aren't &lt;EM&gt;supposed&lt;/EM&gt; to edit default config files, this should also work. But even if it does, follow up with support about the other options.&lt;/P&gt;</description>
      <pubDate>Mon, 26 Oct 2015 06:51:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287425#M54894</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-10-26T06:51:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287426#M54895</link>
      <description>&lt;P&gt;The add-ons will &lt;EM&gt;not&lt;/EM&gt; forward internal Splunk logs...&lt;/P&gt;</description>
      <pubDate>Mon, 26 Oct 2015 06:52:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287426#M54895</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-10-26T06:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287427#M54896</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/139394"&gt;@VipulPathak&lt;/a&gt; - the add-on will be in the $SPLUNK_HOME/etc/apps/Splunk_TA_nix if installed.&lt;/P&gt;

&lt;P&gt;@Iguinn - that's actually not true, the add-on, by default, has a monitor for /var/log, so it'll forward everything inside of that directory, which are "internal" logs to the Forwarder itself (though not internal logs to the Splunk process).  The stanza is:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[monitor:///var/log]
whitelist=(\.log|log$|messages|secure|auth|mesg$|cron$|acpid$|\.out)
blacklist=(lastlog|anaconda\.syslog)
index=os
disabled = 0
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 29 Sep 2020 07:42:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287427#M54896</guid>
      <dc:creator>pickerin</dc:creator>
      <dc:date>2020-09-29T07:42:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287428#M54897</link>
      <description>&lt;P&gt;Splunk does not store its internal log files in &lt;CODE&gt;/var/log&lt;/CODE&gt; - it stores them in &lt;CODE&gt;$SPLUNK_HOME/var/log/splunk&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;Which on a UF installed on Linux would usually be&lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;/opt/splunkforwarder/var/log/splunk&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Oct 2015 18:22:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287428#M54897</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-10-26T18:22:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287429#M54898</link>
      <description>&lt;P&gt;I didn't find "Splunk Add-on for Unix and Linux" on my installation, nor was it installed explicitly by any of the Admin users.&lt;/P&gt;

&lt;P&gt;However, there was another plugin present in  /opt/splunkforwarder/etc/apps/  by default, called "SplunkUniversalForwarder". Inside the plugin directory, there is a default directory that contains an inputs.conf file. This file contains the monitor statements for  $SPLUNK_HOME/var/log  folder.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;################################
# Make sure these get forwarded
################################

[monitor://$SPLUNK_HOME/var/log/splunk/splunkd.log]
disabled = true
_TCP_ROUTING = *
index = _internal

[monitor://$SPLUNK_HOME/var/log/splunk/metrics.log]
disabled = true
_TCP_ROUTING = *
index = _internal
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I disabled them and Bingo, Splunk stopped flooding the destination with Splunk logs, while sending what I asked Splunk to forward.&lt;/P&gt;

&lt;P&gt;Pretty Nice, problem solved. Thanks Pickerin and Lguinn for taking time to discuss and helping me pin point the problem.&lt;/P&gt;

&lt;P&gt;However, it is really strange to see that any plugin can change the overall behavior of Splunk as a whole. Wouldn't that be cool, if a changes in the DEFAULT of any plugins, only affect that Plugin and not all applications as a whole ?&lt;/P&gt;

&lt;P&gt;Thanks for the help.&lt;/P&gt;

&lt;P&gt;-Vipul.&lt;/P&gt;</description>
      <pubDate>Mon, 26 Oct 2015 22:27:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287429#M54898</guid>
      <dc:creator>VipulPathak</dc:creator>
      <dc:date>2015-10-26T22:27:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to tell a Splunk Universal Forwarder to not to monitor its own log files?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287430#M54899</link>
      <description>&lt;P&gt;Having tried to disable monitoring of the metrics and splunkd logs today, it does look as though disabled = 1 doesnt work for these sources on the universal forwarder. There are monitors for these in both the splunk universal forwarder app on the splunk forwarder and in the system default. I put an entries in system local to disable all the them and checked btool after a restart to confirm they are disabled. However internal logs still get forwarded. I didnt try hardcoding into default, cos that is just a pain. I guess another option would be to nullqueue on the indexers. However it is frustrating that this doesnt appear to work in accordance with accepted Splunk rules.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Dec 2016 02:26:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-tell-a-Splunk-Universal-Forwarder-to-not-to-monitor-its/m-p/287430#M54899</guid>
      <dc:creator>pj</dc:creator>
      <dc:date>2016-12-16T02:26:06Z</dc:date>
    </item>
  </channel>
</rss>

