Skip to content

Commit e827393

Browse files
author
Kubernetes Submit Queue
authored
Merge pull request kubernetes#39598 from Crassirostris/fluentd-self-logs-fix
Automatic merge from submit-queue Fix fluentd-gcp image config by avoiding processing its own logs Section, discarding all records generated by fluentd itself from the pipeline was deleted by mistake in kubernetes#37681. Returning it back and expanding the comment. Not bumping image version for the later cumulative update. CC @piosz
2 parents ee177db + 57ec7b7 commit e827393

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

cluster/addons/fluentd-elasticsearch/fluentd-es-image/td-agent.conf

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@
100100
# problem yet to be solved as secrets are not usable in static pods which the fluentd
101101
# pod must be until a per-node controller is available in Kubernetes.
102102

103-
# Do not directly collect fluentd's own logs to avoid infinite loops.
103+
# Prevent fluentd from handling records containing its own logs. Otherwise
104+
# it can lead to an infinite loop, when error in sending one message generates
105+
# another message which also fails to be sent and so on.
104106
<match fluent.**>
105107
type null
106108
</match>

cluster/addons/fluentd-gcp/fluentd-gcp-image/fluent.conf

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,13 @@
3939
# the name of the Kubernetes container regardless of how many times the
4040
# Kubernetes pod has been restarted (resulting in a several Docker container IDs).
4141

42+
# Prevent fluentd from handling records containing its own logs. Otherwise
43+
# it can lead to an infinite loop, when error in sending one message generates
44+
# another message which also fails to be sent and so on.
45+
<match fluent.**>
46+
type null
47+
</match>
48+
4249
# Example:
4350
# {"log":"[info:2016-02-16T16:04:05.930-08:00] Some log text here\n","stream":"stdout","time":"2016-02-17T00:04:05.931087621Z"}
4451
<source>

0 commit comments

Comments
 (0)