Getting Data In

how to monitor perticular files

vaibhavbeohar
Path Finder

Hi,

How do I create a forwarder to get particular file from a directory, suppose want to index log file from 3 days only and in that directory files are older than a month how do I configure in Splunk forwarder.like

    u_ex120201.log
u_ex120202.log
u_ex120203.log
u_ex120204.log    
        .
        .
        .
   u_ex120312.log
   u_ex120313.log
   u_ex120314.log


   Thanks.
Tags (1)
0 Karma

jbsplunk
Splunk Employee
Splunk Employee

I think these links will be useful for education purposes:

http://docs.splunk.com/Documentation/Splunk/latest/admin/inputsconf
http://docs.splunk.com/Documentation/Splunk/latest/data/Specifyinputpathswithwildcards

A more direct answer is you might use something like this in your inputs.conf:

[monitor://path/to/file/u_ex*.log]
IgnoreOlderThan = 3d
0 Karma
Get Updates on the Splunk Community!

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...