Przeglądaj źródła

Support monitoring for bond interfaces via telegraf

Change-Id: I963dbca50f9ce9f7ad4913640e18833039b68992
Partial-Bug: PROD-16264
pull/148/merge
Mateusz Matuszkowiak 6 lat temu
rodzic
commit
7399519b94
2 zmienionych plików z 20 dodań i 0 usunięć
  1. +9
    -0
      linux/files/telegraf.conf
  2. +11
    -0
      linux/meta/telegraf.yml

+ 9
- 0
linux/files/telegraf.conf Wyświetl plik

@@ -0,0 +1,9 @@
[[inputs.bond]]
{%- include 'telegraf/files/input/_common.conf' %}
{%- if values.bond_interfaces is defined %}
bond_interfaces = {{ values.bond_interfaces | json }}
{%- endif %}
{%- if values.host_proc is defined %}
host_proc = "{{ values.host_proc | json }}"
{%- endif %}
{%- include 'telegraf/files/input/_filters.conf' %}

+ 11
- 0
linux/meta/telegraf.yml Wyświetl plik

@@ -1,3 +1,4 @@
{%- from "linux/map.jinja" import monitoring with context %}
agent:
input:
cpu:
@@ -23,3 +24,13 @@ agent:
swap:
system:
linux_sysctl_fs:
{%- if monitoring.bond_status.interfaces is defined and monitoring.bond_status.interfaces %}
bond:
template: linux/files/telegraf.conf
{%- if monitoring.bond_status.interfaces is list %}
bond_interfaces: {{ monitoring.bond_status.interfaces }}
{%- endif %}
{%- if monitoring.bond_status.host_proc is defined %}
host_proc: {{ monitoring.bond_status.host_proc }}
{%- endif %}
{%- endif %}

Ładowanie…
Anuluj
Zapisz