Getting Data In

Is it possible to have a Splunk forwarder remove data from a monitored file after it has been successfully forwarded to an indexer?

LewisWheeler
Communicator

I read somewhere this is possible, however I can't find where or how - looking for confirmation:

Essentially I have the below scenario:
FileA is being monitored by ForwarderA for new data. When new data is added to FileA, then ForwarderA will send this data to IndexerA and confirm receipt. Once completed, I want ForwarderA to remove the data it has transmitted successfully from FileA.

Does anyone know if this is possible and if so how one might go about doing this?

Tags (2)
0 Karma
1 Solution

LewisWheeler
Communicator

Yes this can be done, Batch Mode should be configured on the directory/file as per the below configuration:
http://docs.splunk.com/Documentation/Splunk/latest/Admin/Inputsconf?utm_source=answers&utm_medium=in...

View solution in original post

0 Karma

jeffland
SplunkTrust
SplunkTrust

You use the batch input method instead of a monitor to remove files after reading them.

0 Karma

jeffland
SplunkTrust
SplunkTrust

Sorry for writing a second answer, I couldn't see that your answer was still in moderation.

0 Karma

LewisWheeler
Communicator

No worries - I guessed that was the case

0 Karma

LewisWheeler
Communicator

Yes this can be done, Batch Mode should be configured on the directory/file as per the below configuration:
http://docs.splunk.com/Documentation/Splunk/latest/Admin/Inputsconf?utm_source=answers&utm_medium=in...

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Index This | What travels the world but is also stuck in place?

April 2026 Edition  Hayyy Splunk Education Enthusiasts and the Eternally Curious!   We’re back with this ...

Discover New Use Cases: Unlock Greater Value from Your Existing Splunk Data

Realizing the full potential of your Splunk investment requires more than just understanding current usage; it ...

Continue Your Journey: Join Session 2 of the Data Management and Federation Bootcamp ...

As data volumes continue to grow and environments become more distributed, managing and optimizing data ...