1

I need to measure the datarates of packets between multiple servers. I need pairwise bandwidths between the servers (if possible even the ports), not the overall datarate per interface on each server.

Example output

Timestamp Server A to B Server B to A Server A to C Server C to A
0 1 2 1 5
1 5 3 7 1

What I tried or thought of

  1. tcpdump - I was capturing all the packets and looking at ip.len for getting the datarates. It worked quite well till I started testing along with TC. Turns out tcpdump captures packets at a lower layer than TC. So, the bandwidths I measure using this can't see the limit set by TC.
  2. netstat - I tried using this by greping the output and look at Recv-Q and Send-Q columns. But later I found out that it reports the bytes that have been received and are buffered, waiting for the local process that is using this connection to read and consume them. I won't be able to use them to get bandwidth being used.
  3. iftop - Amazing GUI and has all the things I need. But no way to get the output in a good way to process. Might also overwhelm the storage because of the amount of extra text it stores along with.
  4. bwm-ng - Gives overall datarate per interface on each server but not pairwise.

Please let me know if there are any other ways to achieve what I need. Thanks in advance for your help.

1
  • iptables/ipset/nftables counters, pmacct. Its called traffic accountig not bandwith measuring. Bandwith is about iperf Commented Sep 22, 2022 at 4:45

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.