balena-os / balena-supervisor

Balena Supervisor: balena's agent on devices.
https://balena.io
Other
150 stars 63 forks source link

Include IP table bandwidth usage in device metrics #1724

Open 20k-ultra opened 3 years ago

20k-ultra commented 3 years ago

Check IP tables for bandwidth and include this in device metrics stats.

This data is only updated once an hour so if you download something at 6:15 then the bandwidth will only appear at 7.

If IP tables needs to be configured to track bandwidth then if device metrics is enabled then make sure IP tables is tracking bandwidth. If metrics are disabled then tell IP tables to stop tracking. If there's minimal cost for IP tables to always be tracking then don't bother having a toggle and just leave it always enabled.

JF improvement: https://jel.ly.fish/d12b9212-73c6-440f-b813-55c277c061e5

20k-ultra commented 3 years ago

This metric would display in the dashboard next to the other metrics. However, we'd have 5 metrics and could try to add 1 more metric to make it an even 6 :)

edit: or make the network usage 1 big bar that takes up 2 spaces if we make it a bar to show usage over time ?

jellyfish-bot commented 3 years ago

[alexgg] This issue has attached support thread https://jel.ly.fish/f6e91758-24dd-4832-a377-5077d2d512e3