Skip to content

Commit a91bcea

Browse files
committed
Fluentd fixes
1 parent 5e1766a commit a91bcea

File tree

5 files changed

+31
-12
lines changed

5 files changed

+31
-12
lines changed

services/logging/docker-compose.local.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,8 @@ services:
1313
deploy:
1414
placement:
1515
constraints: []
16+
17+
fluentd:
18+
deploy:
19+
placement:
20+
constraints: []

services/logging/docker-compose.yml.j2

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
version: "3.8"
21
services:
32
# MongoDB: https://hub.docker.com/_/mongo/
43
mongodb:
@@ -102,7 +101,7 @@ services:
102101
- traefik.http.middlewares.graylog_replace_regex.replacepathregex.replacement=/$${1}
103102
- traefik.http.routers.graylog.middlewares=ops_whitelist_ips@swarm, ops_gzip@swarm, graylog_replace_regex
104103
fluentd:
105-
image: itisfoundation/fluentd:v1.16.8-1.0
104+
image: itisfoundation/fluentd:v1.16.9-1.0
106105
configs:
107106
- source: fluentd_config
108107
target: /fluentd/etc/fluent.conf

services/logging/fluentd/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM fluent/fluentd:v1.16.8-1.0
1+
FROM fluent/fluentd:v1.16.9-1.0
22

33
USER root
44

services/logging/fluentd/Makefile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.DEFAULT_GOAL := help
2+
STACK_NAME = $(notdir $(shell pwd)/..)
3+
REPO_BASE_DIR := $(shell git rev-parse --show-toplevel)
4+
5+
# TARGETS --------------------------------------------------
6+
include ${REPO_BASE_DIR}/scripts/common.Makefile
7+
8+
build:
9+
@docker build -t itisfoundation/fluentd:v1.16.9-1.0 .

services/logging/fluentd/fluent.conf

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
metrics_path metrics
1414
</source>
1515

16-
#<system>
17-
# log_level debug
18-
#</system>
16+
<system>
17+
workers 1
18+
</system>
1919

2020
<source>
2121
@type prometheus_output_monitor
@@ -49,7 +49,7 @@
4949
# Output to Graylog using GELF
5050
<store>
5151
@type gelf
52-
host graylog
52+
host logging_graylog
5353
port 12201
5454
protocol udp
5555
add_msec_time true
@@ -59,10 +59,14 @@
5959
path /fluentd/buffer/graylog
6060
flush_thread_count 8
6161
flush_interval 5s
62-
retry_forever true
63-
retry_max_interval 30
62+
retry_forever false
63+
retry_timeout 1h
64+
retry_max_times 30
65+
retry_randomize true
6466
chunk_limit_size 8M
65-
total_limit_size 1G
67+
total_limit_size 2G
68+
overflow_action drop_oldest_chunk
69+
flush_mode interval
6670
</buffer>
6771
<secondary>
6872
@type file
@@ -88,10 +92,12 @@
8892
path /fluentd/buffer/loki
8993
flush_thread_count 8
9094
flush_interval 5s
91-
retry_forever true
95+
retry_forever false
9296
retry_max_interval 30
97+
retry_max_times 30
98+
retry_randomize true
9399
chunk_limit_size 8M
94-
total_limit_size 1G
100+
total_limit_size 2G
95101
</buffer>
96102
<secondary>
97103
@type file

0 commit comments

Comments
 (0)