[Winpcap-users] timestamping and huge latency

Gianluca Varenni gianluca.varenni at cacetech.com
Wed Sep 22 10:02:56 PDT 2010


Disregard my reply. I confused this thread with the other one related to strange reception delays.

Have a nice day
GV


From: Gianluca Varenni 
Sent: Wednesday, September 22, 2010 9:51 AM
To: winpcap-users at winpcap.org 
Subject: Re: [Winpcap-users] timestamping and huge latency


He is measuring the delay between two consecutive packets. Lack of sync between transmitter and receiver clocks would not cause those delays.

GV


From: "Fish" (David B. Trout) 
Sent: Wednesday, September 22, 2010 3:30 AM
To: winpcap-users at winpcap.org 
Subject: Re: [Winpcap-users] timestamping and huge latency


Another thing: if the sending and receiving/capturing systems' clocks are not synchronized with each other, then how are you measuring the supposed latency between sending and receiving/capturing?

 

That is to say, if the two clocks are not synchronized with one another, then normal clock drift would completely invalidate your measured latency in my opinion.

 

Are the two system's clocks synchronized with one another?

 

If they're not then there's your answer.

 

 

 

p.s. if/when you do synchronize them with each other, remember to ensure that either: a) neither or them synchronizes with an external clock, or: b) only ONE of them does! (but not both!)  The same rule applies to the Windows Time Service too: disable it on both or else ensure the one with it enabled is configured as the "time server".  Otherwise your results would once again be completely invalid/inconclusive.

-- 
  "Fish"  (David B. Trout) 
    fish at softdevlabs.com

 

From: winpcap-users-bounces at winpcap.org [mailto:winpcap-users-bounces at winpcap.org] On Behalf Of Helmut Vaupotitsch
Sent: Tuesday, September 14, 2010 9:18 AM
To: winpcap-users at winpcap.org
Subject: [Winpcap-users] timestamping and huge latency
Importance: High

 

Hi Gianluca and all others,

I am facing a major latency problem on *long lasting* capture sessions which maybe 
has to do with timestamping by the driver, every hint to solve it is appreciated:

We developed a proprietary protocol to configure, manage and monitor 
our self-developed hardware, the config software uses WinPCap to capture and send raw packets.

Everything is working fine, but after some days of continuous capturing i face:
- On some machines, the latency between sending requests and receiving the answer 
  increases to some seconds (can be up to >30 secs after capturing for a week!)
Closing and re-opening the driver would solve the problem, but i definitely need to capture
for months and longer without interrupt!

I know that the driver timestamp is drifting apart from the System Time(which can be
synchronized by e.g. a NTP server), therefore i timestamp the frames my myself(which 
is also important if a use timeouts)

My question is:
What could be the reason(s) for huge latency on long lasting captures?
I know that the latency increases on receiving packets
Currently i don´t know if sending´s latency also increases
Maybe it has something to do with the GetSystemTimeAdjustment setting?


Thanks for reading

Best regards from Austria
Helmut


Gianluca Varenni schrieb: 

The return value of QuerySystemTime and QueryPerformanceCounter is synchronized at the beginning of the capture (to compute the offset between epoch time and QueryPerformanceCounter), and then the counter and frequency returned by QPC are used to compute the number of seconds (and microseconds) and added to the offset. The timestamping code is available in the source code of WinPcap, winpcap\packetntx\driver\time_calls.h Have a nice dayGV   --------------------------------------------------From: "Jan Martinec" <martij12 at fel.cvut.cz>Sent: Tuesday, September 14, 2010 7:23 AMTo: <winpcap-users at winpcap.org>Subject: [Winpcap-users] timestamp   Hello!I've got a question about timestamping method. I know that a timestampis got using method QueryPerformanceCounter (resp.keQueryPerformanceCounter), which is a number of ticks of Performancecounter. But timestamp is by Winpcap returned in "Seconds since Epoch"format. So how is the recomputation done? Thank you very much Best regards,Jan Martinec  _______________________________________________Winpcap-users mailing listWinpcap-users at winpcap.orghttps://www.winpcap.org/mailman/listinfo/winpcap-users      _______________________________________________Winpcap-users mailing listWinpcap-users at winpcap.orghttps://www.winpcap.org/mailman/listinfo/winpcap-users   



-- ----------------------------------------------------------------Ing. Helmut Vaupotitsch        Phone:  +43 (0)3133 3780 16ITEC Tontechnik und            Fax:    +43 (0)3133 3780 9Industrieelektronik GmbH       E-mail: hv at itec-audio.comA-8200 Lassnitzthal 300        URL:    http://www.itec-audio.com----------------------------------------------------------------

--------------------------------------------------------------------------------


_______________________________________________
Winpcap-users mailing list
Winpcap-users at winpcap.org
https://www.winpcap.org/mailman/listinfo/winpcap-users



--------------------------------------------------------------------------------


_______________________________________________
Winpcap-users mailing list
Winpcap-users at winpcap.org
https://www.winpcap.org/mailman/listinfo/winpcap-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.winpcap.org/pipermail/winpcap-users/attachments/20100922/cac389a3/attachment-0001.htm 


More information about the Winpcap-users mailing list