Setup logstash to stop reading a file after some time

We are using logstsash to read a folder to read logs, due to log rotation tons of files are being created in the folder, what if I want logstash to stop reading from a file if there is no new data in a file for 5 minutes.

If you mean you want logstash to stop monitoring a file if there is a gap of more than five minutes then that cannot be done. If you just want it to close the file then look at the close_older option.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.