Getting Data In

Monitor a directory for new files

adityaanand
Explorer

Hi,
I am trying to monitor a directory.
Suppose that there is a directory named test and it contains initially a log file called access.log.
The access.log file contains following data.
210.160.24.63 - - [07/May/2015:18:22:16] "GET /product.screen?productId=WC-SH-A02&JSESSIONID=SD0SL6FF7ADFF4953 HTTP 1.1" 200 3878 "http://www.google.com" "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.5 (KHTML, like Gecko) Chrome/19.0.1084.46 Safari/536.5" 349
.....
.....
It is showing that 13,628 events are indexed.

Now i added an another file access1.log in same directory (test). with little with changes in the file. I have replace 210.160.24.63 with 190.160.24.63 and all other contents are same as it is.

But still in search It is showing that 13,628 events .

I have checked that through CLI that both files are listed in monitor directory.

But i am not getting expected results i.e. events should be increased.

Please help me .

0 Karma

kheli
Path Finder

add crcSalt = under your monitor stanza

0 Karma

tom_frotscher
Builder

Are the first few lines of the documents exactly the same? Or did the change of the ip influence the also the first few lines of the document?

0 Karma

adityaanand
Explorer

No the first line of the document is not exactly same.
I have already mentioned that the first line stated with 210.160.24.63 ... is replaced with 190.160.24.63 and rest of are exactly same.

0 Karma

tom_frotscher
Builder

Ok, sorry but from your post it was not completely clear for me that you changed the first line.

Can you provide the corresponding monitoring stanza from your inputs.conf ?

0 Karma

adityaanand
Explorer

[monitor://D:/\Splunk Data/\Testing]
disabled = true
index = splunk_test

0 Karma

tom_frotscher
Builder

Your input is disabled, change to disabled = false.

0 Karma

adityaanand
Explorer

I have changed to disabled = false.
Still i am getting same result.

0 Karma

tom_frotscher
Builder

Have you changed this setting in the default or in the local directory? Can you find your input in the web ui? In the web ui and in the correct app context go to settings -> data inputs -> files and directories. Is your input in this list and displayed as "enabled"?

0 Karma

adityaanand
Explorer

I have made changes in C:\Program Files\Splunk\etc\apps\search\local\inputs.conf.
i have aslo gone through web ui. I found there status= enabled and no. of file = 1.

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Can’t Make It to Boston? Stream .conf25 and Learn with Haya Husain

Boston may be buzzing this September with Splunk University and .conf25, but you don’t have to pack a bag to ...

Splunk Lantern’s Guide to The Most Popular .conf25 Sessions

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Unlock What’s Next: The Splunk Cloud Platform at .conf25

In just a few days, Boston will be buzzing as the Splunk team and thousands of community members come together ...