Getting Data In

How does a Splunk forwarder read a file?

skoelpin
SplunkTrust
SplunkTrust

We are constantly writing to a file and cannot have the file open as it's being written to.

What permissions does a Splunk forwarder need to forward data?

Does a Splunk forwarder "open" the file to read its contents?

0 Karma
1 Solution

ddrillic
Ultra Champion

On Linux, it needs the read permission. The following explains it - Permissions on /var/log

View solution in original post

0 Karma

inventsekar
SplunkTrust
SplunkTrust

How Splunk Enteprise monitors nonwritable Windows files
Windows can prevent Splunk from reading open files. If you need to read files while they are being written to, you can use the monitorNoHandle input.

Why use MonitorNoHandle?
This Windows-only input lets you read files on Windows systems as Windows writes to them. It does this by using a kernel-mode filter driver to capture raw data as it gets written to the file. Use this input stanza on files which get locked open for writing. You can use this input stanza on a file which the system locks open for writing, such as the Windows DNS server log file.

Note: MonitorNoHandle only works on Windows Vista or Windows Server 2008 and later operating systems. You can only monitor single files with MonitorNoHandle. You can not monitor directories. If a file you choose to monitor already exists, Splunk does not index its current contents, only new information that comes into the file as it gets written to.

from - http://docs.splunk.com/Documentation/Splunk/6.4.2/Data/Monitorfilesanddirectories

thanks and best regards,
Sekar

PS - If this or any post helped you in any way, pls consider upvoting, thanks for reading !

ddrillic
Ultra Champion

On Linux, it needs the read permission. The following explains it - Permissions on /var/log

0 Karma

skoelpin
SplunkTrust
SplunkTrust

What about a Windows server?

0 Karma

somesoni2
Revered Legend

Same. Read permission

0 Karma
Get Updates on the Splunk Community!

Unlock Database Monitoring with Splunk Observability Cloud

  In today’s fast-paced digital landscape, even minor database slowdowns can disrupt user experiences and ...

Purpose in Action: How Splunk Is Helping Power an Inclusive Future for All

At Cisco, purpose isn’t a tagline—it’s a commitment. Cisco’s FY25 Purpose Report outlines how the company is ...

[Upcoming Webinar] Demo Day: Transforming IT Operations with Splunk

Join us for a live Demo Day at the Cisco Store on January 21st 10:00am - 11:00am PST In the fast-paced world ...