telegraf/plugins/inputs/bond
Joshua Powers 6fa29f2966
fix: markdown: resolve all markdown issues with a-c (#10169)
2021-11-24 11:55:55 -07:00
..
README.md fix: markdown: resolve all markdown issues with a-c (#10169) 2021-11-24 11:55:55 -07:00
bond.go refactor: move from io/ioutil to io and os package (#9811) 2021-09-28 15:16:32 -06:00
bond_test.go feat: add count of bonded slaves (for easier alerting) (#9762) 2021-09-15 11:56:52 -06:00

README.md

Bond Input Plugin

The Bond input plugin collects network bond interface status for both the network bond interface as well as slave interfaces. The plugin collects these metrics from /proc/net/bonding/* files.

Configuration

[[inputs.bond]]
  ## Sets 'proc' directory path
  ## If not specified, then default is /proc
  # host_proc = "/proc"

  ## By default, telegraf gather stats for all bond interfaces
  ## Setting interfaces will restrict the stats to the specified
  ## bond interfaces.
  # bond_interfaces = ["bond0"]

Measurements & Fields

  • bond

    • active_slave (for active-backup mode)
    • status
  • bond_slave

    • failures
    • status
    • count

Description

active_slave
  Currently active slave interface for active-backup mode.

status
  Status of bond interface or bonds's slave interface (down = 0, up = 1).

failures
  Amount of failures for bond's slave interface.

count
  Number of slaves attached to bond

Tags

  • bond

    • bond
  • bond_slave

    • bond
    • interface

Example output

Configuration:

[[inputs.bond]]
  ## Sets 'proc' directory path
  ## If not specified, then default is /proc
  host_proc = "/proc"

  ## By default, telegraf gather stats for all bond interfaces
  ## Setting interfaces will restrict the stats to the specified
  ## bond interfaces.
  bond_interfaces = ["bond0", "bond1"]

Run:

telegraf --config telegraf.conf --input-filter bond --test

Output:

* Plugin: inputs.bond, Collection 1
> bond,bond=bond1,host=local active_slave="eth0",status=1i 1509704525000000000
> bond_slave,bond=bond1,interface=eth0,host=local status=1i,failures=0i 1509704525000000000
> bond_slave,host=local,bond=bond1,interface=eth1 status=1i,failures=0i 1509704525000000000
> bond_slave,host=local,bond=bond1 count=2i 1509704525000000000
> bond,bond=bond0,host=isvetlov-mac.local status=1i 1509704525000000000
> bond_slave,bond=bond0,interface=eth1,host=local status=1i,failures=0i 1509704525000000000
> bond_slave,bond=bond0,interface=eth2,host=local status=1i,failures=0i 1509704525000000000
> bond_slave,bond=bond0,host=local count=2i 1509704525000000000