First time here? Check out the FAQ!
THIS IS A TEST INSTANCE. Feel free to ask and answer questions, but take care to avoid triggering too many notifications.
0

How can i log the received bandwidth every 1ms of an UDP application?

Dear community! I want to have a trace of the received bandwidth every 1ms or less . Do you know how could i perform it with wireshark?

Thank you!

Regards,

asked 2018-07-03 09:30:26 +0000
This post is a wiki. Anyone with karma >750 is welcome to improve it.
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

3 Answers

0

Wireshark isn't really the tool for this, it's a packet analyzer not a network monitor. You could capture with Wireshark using a capture filter to limit the traffic to that created by your application and then post-process the resulting capture file using a programming language with pcap support to separate the traffic into 1ms blocks and then calculate the total traffic received in each block.

You might struggle to find any existing tool that can determine the bandwidth over such a small period of 1ms.

grahamb's avatar
23.8k
grahamb
answered 2018-07-03 09:53:40 +0000
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments
0

Have you tried the io graphs?

thetechfirm's avatar
96
thetechfirm
answered 2018-07-03 11:09:46 +0000
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments
0

As "thetechfirm" already wrote, IO Graphs can show you the bandwidth used with a granularity of 1ms.

Statistics -> I/O Graph, select Bits as your Y-axis and fill out display filter if you so desire to focus on specific traffic. Then at the bottom of the graph window, in the "Interval" drop-down you select 1ms.

You can also export the data by clicking Save As and import it into Excel or similar for graphing.

It is also possible to use Riverbeds excellent SteelCentral Packet Analyzer software which comes in different flavors. That can also (very easily) show you bandwidth usage with 1ms granularity. It excels working with very large capture files, where Wireshark unfortunately typically gives up.

NJL's avatar
120
NJL
answered 2018-07-03 12:42:43 +0000
edit flag offensive 0 remove flag delete link

Comments

Be careful with use of IO graphs or other software-only tool; even though it might have the granularity of ms, the precision and accuracy of the timestamp used to derive though statistics is due to the underlying OS or other capture mechanism. I have seen where, for instance, a laptop with USB ethernet interface can introduce 10s of ms into the jitter of the stream.

Make sure your underlying capture technique can handle what you are looking for - you may need special hardware to do the capture, then analyze as others have described.

Bob Jones's avatar Bob Jones (2018-07-04 00:12:15 +0000) edit

Thank you @NJL and @Bob for your reply, Do you think that with PC i5 OS: ubuntu 16.04, I could have a precise capture?

ims's avatar ims (2018-07-04 09:30:40 +0000) edit

No, you need special capture cards for that. E.g. from profishark, endace or napatech for example.

Christian_R's avatar Christian_R (2018-07-04 10:48:38 +0000) edit

Okay, Thank you!

ims's avatar ims (2018-07-04 11:29:27 +0000) edit

@Bob: thanks for the heads-up. Do you know of any comparison of the accuracy of different capture types e.g. SPAN, capture on laptops, servers, special NICs/capture cards etc.? I can easily imagine a USB ethernet NIC is not particular accurate, but I'd really like to see scientific evidence of what you can expect from various methods.

NJL's avatar NJL (2018-07-04 17:38:03 +0000) edit
add a comment see more comments

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss.

Add Answer