ntp in python

Janto Dreijer jantod at gmail.com
Tue Aug 29 13:52:52 EDT 2006


Janto Dreijer wrote:
> Jeremy Sanders wrote:
> > Janto Dreijer wrote:
> >
> > > I want to measure the packet delivery delays over various network
> > > links. For this I need to synchronise the times of the sender and
> > > receiver, either against NTP or eachother.
> >
> > Couldn't you just use NTP itself to get the delivery delay? You can read the
> > delay out from the ntpdc console using dmpeers, or lopeers in ntpq. You
> > could have two peers either side of the link and measure the delay from
> > NTP.
> >
> > You may also be able to query remote ntp servers to get their delays to
> > their peers.
>
> Unfortunately I don't think that would work for me. I need the delay of
> a stream of packets. Not just a single delay number. More specifically:
> I'm testing RTP (VoIP) packet speeds and would like to predict lag
> (ignoring jitter...separate measurement).

(replying to myself here)

More importantly, it looks like some of the network firewalls I'll be
testing though block the ports typically used by NTP...I hope I'm
wrong.

Maybe I'd be better off writing my own implementation that synchronises
the two pc clocks. Any hints? :-)




More information about the Python-list mailing list