Post

Fluentd 를 Prometheus 로 모니터링 하기

Fluentd 를 Prometheus 로 모니터링 하기

⛳ 들어가기 전에..

  • fluentd는 td-agent 를 사용

📌 Prometheus

Prometheus 플러그인은 총 6개를 제공

image

⚾ 샘플

input plugin 은 promethues 사용해서 server_ip:24231/metrics 를 리스닝 상태로 두고

output plugin은 prometheus_output_monitor 사용해서 10 초마다 promethues 에서 pull 해가도록 한다.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
<source>
  @type prometheus
  bind 0.0.0.0
  port 24231
  metrics_path /metrics
</source>

<source>
  @type prometheus_output_monitor
  interval 10
  <labels>
    hostname ${hostname}
  </labels>
</source>

image

This post is licensed under CC BY 4.0 by the author.