Re: tcptrace [OFFTOPIC?] Looking for cheap timestamping...

From: Jeremy Elson (jelson@circlemud.org)
Date: 02/27/03


Message-Id: <200302272032.h1RKWSD11043@cambot.circlemud.org>
Subject: Re: tcptrace [OFFTOPIC?] Looking for cheap timestamping... 
Date: Thu, 27 Feb 2003 12:32:28 -0800
From: Jeremy Elson <jelson@circlemud.org>

uaca@alumni.uv.es writes:
>I'm looking for inexpensive Gigabit Ethernet hardware that could attach to
>Linux with basic packet timestamping capabilities.

I've never used Gigabit ethernet, but using the libpcap library to
capture packets gives us excellent timestamps for 100mbit ethernet.
Most ethernet drivers timestamp packets in the interrupt handler so it
has fairly low jitter. This timestamp is available if you use libpcap
to capture the packets, as opposed to the normal socket interface in
which case it's not available through any mechanism I know.

Such in-kernel timestamping uses the kernel's internal gettimeofday()
which has 1 usec resolution. Because of the low jitter, we've been
able to use this feature to get order-1 usec precision timesync
between machines, as described in our OSDI 2002 paper at
http://lecs.cs.ucla.edu/Publications/papers/broadcast-osdi.pdf

Our code is available online at http://cvs.cens.ucla.edu. In
particular, the file
http://cvs.cens.ucla.edu/lxr/source//cens/timesync/syncd/driver_udp.c
shows how to read UDP datagrams using libpcap and extract the
kernel-generated timestamps.

Regards,
Jeremy
----------------------------------------------------------------------------
To unsubscribe, send a message with body containing "unsubscribe tcptrace" to
majordomo@tcptrace.org.



This archive was generated by hypermail 2b30 : 02/28/03 EST