python-diamond / Diamond

Diamond is a python daemon that collects system metrics and publishes them to Graphite (and others). It is capable of collecting cpu, memory, network, i/o, load and disk metrics. Additionally, it features an API for implementing custom collectors for gathering metrics from almost any source.
http://diamond.readthedocs.org/
MIT License
1.74k stars 602 forks source link

NetworkCollector sends absurd data to grafana #730

Closed pzystorm closed 2 years ago

pzystorm commented 5 years ago

traffic

Look at the graph. In the time of that peak I have downloaded a 1.8GB file. The graph displays the rx_byte metric of the NetworkCollector. Can someone explains the data which is send to grafana?

If I extract the data of the graph above out of influxdb:

> SELECT rx_byte FROM "network" WHERE ("host" = 'firewall' AND "interface" = 'enp3s0')
name: network
time                rx_byte
----                -------
1552247472000000000 7523
1552247772000000000 7989
1552248072000000000 8431
1552248372000000000 15799
1552248672000000000 10260
1552248972000000000 7707
1552249272000000000 8549
1552249572000000000 3278446
1552249872000000000 2628956
1552250172000000000 9005
1552250472000000000 7370
1552250772000000000 11433
root@firewall:/usr/local# cat /proc/net/dev | grep enp3s0
enp3s0: 430625254007 1577882919    0    0    0     0          0   3068321 32554934262 133811049    0    0    0     0       0          0

The counter is already high... rx_bytes is 430625254007 ... so around 430GB But the counter has increased while downloading the 1.8GB file for that size. I have checked this.

shortdudey123 commented 2 years ago

rx_bytes is a rate (bytes per second), not just a counter that increments. If this does not answer your question, reopen.