The Network I/O metrics (netif) input plugin gathers network traffic information of the running system at regular intervals, and reports them.
The Network I/O metrics plugin creates metrics that are log-based, such as JSON payload. For Prometheus-based metrics, see the Node Exporter metrics input plugin.
Configuration parameters
The plugin supports the following configuration parameters:
Key
Description
Default
Interface
Specify the network interface to monitor. For example, eth0.
none
Interval_Sec
Polling interval (seconds).
1
Interval_NSec
Polling interval (nanosecond).
0
Verbose
If true, gather metrics precisely.
false
Test_At_Init
If true, testing if the network interface is valid at initialization.
false
Threaded
Indicates whether to run this input in its own thread.
false
Get started
To monitor network traffic from your system, you can run the plugin from the command line or through the configuration file:
Command line
Run Fluent Bit using a command similar to the following:
fluent-bit-inetif-pinterface=eth0-ostdout
Which returns something the following:
Configuration file
In your main configuration file append the following:
Which calculates using the formula: Total interval (sec) = Interval_Sec + (Interval_Nsec / 1000000000).