Monitor network health

Hi,
I was wondering if there is a way to continually monitor the network health/performance (WiFi and/or Ethernet) over time.
My question is more about measuring consistency than peak performance.

For example, if I could measure a sort of “response time”: how does it take for each packet transferred from/to device to/from router, plot the values over time (maybe a day); change to Ethernet the next day, overlay the plots.

The measurement has to be done during normal use; ping , iperf3 will give me momentary picture.

Does this make sense?

Thanks

1 Like

What type of monitoring you can do depends on what your network hardware will support. Most switches/routers/servers/etc. will allow you to use SNMP to monitor packet counts and throughput on each port.

More advanced devices may allow you to export NetFlow data to a central monitoring system, which will give you a complete picture of the network traffic. Though you’ll need to figure out how to turn all that data into a useful report.

While you say ping only gives you a momentary picture, your network monitoring system (e.g. Nagios, Cacti, etc.) will allow you to set-up ping monitors of any device on your network, at arbitrary intervals. You can set-up a ping check of a server, router, L3 switch IP addresses, or similar, as often as every minute. This will report rount-trip times, downtime and packet loss over days, weeks and months, and even graph those results.

Thanks for your reply.
The ping ideas is actually not bad.

What hardware do you have? often times wifi APs will have useful SNMP stuff, like dropped frames and retry latencies.

are you using off the shelf router or something smarter, e.g. any chance you could convert tshark TCP ack latencies into some kind of log you could ingest into a map (and/or convert into pandas maybe and plot using Jupyter?)

Logging ping and/or MTR output into timeseries as rcxb mentioned is also nice, coarse and synthetic but surprisingly useful for basic stuff.

Are you using pihole? Do you have query logging enabled?

Also, QUIC breaks a lot of intermediary quality metrics you can do with TCP (all the pacing and window sizing data is encrypted in quic, you’d need to get it off the client)

For now just the ISP router and my laptop.
I am waiting for Pine64 to make available the Quartz64 Model B 8GB, then use for PiHole, (maybe as router?).

This is one of the reason I thinking about gathering some metrics.

Regarding packet drop I can see something in:

$ cat /proc/net/dev           
Inter-|   Receive                                                |  Transmit
 face |bytes    packets errs drop fifo frame compressed multicast|bytes    packets errs drop fifo colls carrier compressed
    lo:  129949    1328    0    0    0     0          0         0   129949    1328    0    0    0     0       0          0
wlp0s20f3: 5270212702 4281302    0    0    0     0          0         0 355611509 1039000    0    0    0     0       0          0

But it is always 0.

Things like “how long did wifi radio need to wait for noise or other devices to shut up before being able to send a request” exist within the wifi controller and the driver itself will have access to them, but they won’t be exposed further up the stack. Maybe you’ll find something in /sys/net/dev/… not sure where to look OTOH :thinking:

For wifi, I use these U6-LR access points and they have an SNMP option that provides these stats from the AP perspective… which can then go into Prometheus/Grafana or you can look at a unifi dashboard that gives you some random “experience score”.

Re pine64 for a router, how fast is your internet “connection”/“package” is it cable/fibre/vdsl/… ? Asking because, the more firewalling and inspection of traffic you end up doing, the more CPU it’ll take on top of just basic shuffling of a blob of bytes from one queue towards another.

Zabbix is free and relatively easy to set up if you have a spare linux VM or physical host.

The ideas was if I could collect from my laptop side, in order to not affect the rest of the network. In this I can try to measure the real difference between Wifi vs Ethernet, Route vs SBC.