Log rotation logstash


(Andrei Zakabluk) #1

Hi! I save logs
if [type] == "tibco_4" {
file {
path => "/opt/GET_TRACE/ELK/tibco_4/%{source}"
codec => line { format => "custom format: %{message}"}
gzip=> true
}
}
but in my directory /opt/GET_TRACE/ELK/tibco_4 I see:
1.3G esb-esbCore-ems.log
18M iPayGateway-iPayGateway-ems.log
1.6G partnergateway-PartnerGatewayCs-ems.log
Hove I can rotate my logs? SIZE? Time?


(Magnus Bäck) #2

https://www.elastic.co/guide/en/logstash/current/event-dependent-configuration.html#sprintf


(Andrei Zakabluk) #3

tnx. You will can close ticket.


(Magnus Bäck) #4

You will can close ticket.

This isn't a ticket and I can't close it, but you can mark my answer as a solution.


(system) #5

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