Write multiply csv files in logstash output


(yosi) #1

hii ,

i have an input in logstash of beats , and i am writing to csv file in the output .

i want to make a new file of csv in every hour or in every day ?

how i can to define logstash that the current file finish to write close the file and write to other csv file ?

thank you


(Paris Mermigkas) #2

The path option of the file output plugin allows for variable interpolation (as can be seen in the example), so you can use that to rotate files on a specific interval.


(yosi) #3

ok ,

the question is if in each action of filebeat it will be write other file?
and from where it tooks the timestamp?


(Paris Mermigkas) #4

I believe Filebeat creates a @timestamp in each event with the time stamp when it read that specific line, so you can use that.


(system) #5

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