From 5c4e77d81600e56848a63d953cd0ecc4afc9a57f Mon Sep 17 00:00:00 2001 From: Steve Wilkerson Date: Wed, 2 Jan 2019 15:29:03 -0600 Subject: [PATCH] Fluent-logging: Add input and output for qemu logs This adds an input to Fluentbit for capturing all qemu instance logs in /var/log/libvirt/qemu/, and adds an Elasticsearch output for those entries Change-Id: I0802023f9861a5944e7989fd5469133c325349e7 --- fluent-logging/values.yaml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/fluent-logging/values.yaml b/fluent-logging/values.yaml index bd2618733..cfcbb86b5 100644 --- a/fluent-logging/values.yaml +++ b/fluent-logging/values.yaml @@ -130,6 +130,16 @@ conf: DB.Sync: Normal Buffer_Chunk_Size: 1M Buffer_Max_Size: 1M + - qemu: + header: input + Name: tail + Tag: qemu + Path: /var/log/libvirt/qemu/*.log + DB: /var/log/qemu.db + Mem_Buf_Limit: 5MB + DB.Sync: Normal + Buffer_Chunk_Size: 1M + Buffer_Max_Size: 1M - kubelet: header: input Name: systemd @@ -157,6 +167,11 @@ conf: Name: record_modifier Match: libvirt Record: hostname ${HOSTNAME} + - qemu_record_modifier: + header: filter + Name: record_modifier + Match: qemu + Record: hostname ${HOSTNAME} - kernel_record_modifier: header: filter Name: record_modifier @@ -349,6 +364,22 @@ conf: flush_interval: "5" max_retry_wait: 300 disable_retry_limit: "" + - qemu_elasticsearch: + header: match + type: elasticsearch + user: "#{ENV['ELASTICSEARCH_USERNAME']}" + password: "#{ENV['ELASTICSEARCH_PASSWORD']}" + expression: "qemu" + include_tag_key: true + host: "#{ENV['ELASTICSEARCH_HOST']}" + port: "#{ENV['ELASTICSEARCH_PORT']}" + logstash_format: true + logstash_prefix: qemu + buffer_chunk_limit: 2M + buffer_queue_limit: 8 + flush_interval: "5" + max_retry_wait: 300 + disable_retry_limit: "" - journal_elasticsearch: header: match type: elasticsearch