Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David J Taylor
Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
[]
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

For those without wide-bandwidth academic connections - those folks on 
cable or ADSL - how good is an equal split round trip assumption?

David 

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David Malone
David J Taylor david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid 
writes:

Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
[]
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

For those without wide-bandwidth academic connections - those folks on 
cable or ADSL - how good is an equal split round trip assumption?

I have a machine with Rugby reciever that also syncs (over DSL) to
a machine with a GPS unit. Based on that, it looks like the asymetry
is small (not more than a handful of ms, on a path of 32ms).

David.

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David Lord
David J Taylor wrote:
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.
 
 For those without wide-bandwidth academic connections - those folks on 
 cable or ADSL - how good is an equal split round trip assumption?

2Mbit adsl here seems to give me mostly maximum variation of 5-6ms
and for 50% its at 0.6ms or less. Remote connections to my servers
shows offset mostly following what I see here but with occasional
irregular blips of from 5ms to 200ms and these don't always seem
to correspond to any local variation in load or network traffic.
Heavy downloads at 230kB/s sometimes have no effect but other
times I see latency as monitored by my ISP shoot up from  20ms
to  100ms which I believe is down to congestion or throttling in
BT network.


David

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread Jan Ceuleers
David J Taylor wrote:
 For those without wide-bandwidth academic connections - those folks on
 cable or ADSL - how good is an equal split round trip assumption?

I calculated this for my case once (3840 kbit/s down and 512 kbit/s up). The 
difference in transmission time due only to the different bitrates was about 
1.2ms in my case.

This is however only the best case, because it assumes that the uplink is not 
saturated. If it is, and if you are able to prioritise your upstream NTP 
packets over all other traffic, then you need to add half of the transmission 
latency of the average upstream packet to the above 1.2ms.

To give you some idea, assuming that the uplink is saturated due to a file 
upload (i.e. MTU-sized packets), this brings the difference in latency to 
14.4ms (including the above 1.2ms).

If you cannot control upstream priority queuing, then the upstream latency 
depends on the total size of your upstream queue, which may add several 
MTU-sized packet transmission times to the difference (in my case, 26.5ms times 
three plus 1.2ms).

This is then really the worst case, because it assumes that the downlink is not 
saturated so that there is no queueing on the ISP's side.

Cheers, Jan

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David J Taylor

David J Taylor 
david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid wrote in 
message news:%xqgm.126$ym4...@text.news.virginmedia.com...
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

 For those without wide-bandwidth academic connections - those folks on 
 cable or ADSL - how good is an equal split round trip assumption?

 David

Thanks, David, David and Jan.  A few milliseconds is what I had expected, 
so if you are on a consumer line, what implications does that have for 
unruh's comment?

Cheers,
David 

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David Lord
David J Taylor wrote:
 
 David J Taylor 
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid wrote in 
 message news:%xqgm.126$ym4...@text.news.virginmedia.com...
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

 For those without wide-bandwidth academic connections - those folks on 
 cable or ADSL - how good is an equal split round trip assumption?

 David
 
 Thanks, David, David and Jan.  A few milliseconds is what I had 
 expected, so if you are on a consumer line, what implications does that 
 have for unruh's comment?

I'd go for equal split being as good an approximation as any.
Mostly uplinks aren't loaded too much here but I've had altq
running for a few years, which increased my upload from maybe
13kB/s to near 26kB/s and at same time massive latency on
saturated upload link was mostly eliminated. NTP, DNS etc
are also prioritised so possibly my experience isn't typical.

I might leave one of desktops running chrony for an extended
period with same sources as used by one of my local servers
and see how they compare.


David

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David Woolley
Jan Ceuleers wrote:

 This is however only the best case, because it assumes that the
 uplink is not saturated. If it is, and if you are able to prioritise your

I suspect most severe asymmetry cases actually happen because the 
downlink is saturated.  That's is exacerbated by the fact that it is 
more difficult to get the ISP to prioritise, than to do it yourself.

ADSL has a higher download speed because most users receive much more 
than they transmit.

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread John Hasler
David J Taylor writes:
 On consumer-grade circuits the assumption about equal round trip is
 unlikely to be valid.

Why would you expect the asymmetry to be worse there than elsewhere?
-- 
John Hasler 
jhas...@newsguy.com
Dancing Horse Hill
Elmwood, WI USA

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David J Taylor

Unruh unruh-s...@physics.ubc.ca wrote in message 
news:qg_gm.50009$db2.46...@edtnps83...
 David J Taylor 
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid writes:


David J Taylor
david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid wrote in
message news:%xqgm.126$ym4...@text.news.virginmedia.com...
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement 
 over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

 For those without wide-bandwidth academic connections - those folks on
 cable or ADSL - how good is an equal split round trip assumption?

 David

Thanks, David, David and Jan.  A few milliseconds is what I had 
expected,
so if you are on a consumer line, what implications does that have for
unruh's comment?

Cheers,
David

 Which comment?

The one I quoted:

Note that chrony will give you a factor of 2 or three improvement over 
ntp  in the errors, assuming that the roundtrip is equally split on Linux 
or BSD.

On consumer-grade circuits the assumption about equal round trip is 
unlikely to be valid.

I hope that David Lord can make some tests, and I await the results with 
interest.

Cheers,
David 

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread Unruh
David J Taylor david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid 
writes:


Unruh unruh-s...@physics.ubc.ca wrote in message 
news:qg_gm.50009$db2.46...@edtnps83...
 David J Taylor 
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid writes:


David J Taylor
david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid wrote in
message news:%xqgm.126$ym4...@text.news.virginmedia.com...
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement 
 over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

 For those without wide-bandwidth academic connections - those folks on
 cable or ADSL - how good is an equal split round trip assumption?

 David

Thanks, David, David and Jan.  A few milliseconds is what I had 
expected,
so if you are on a consumer line, what implications does that have for
unruh's comment?

Cheers,
David

 Which comment?

The one I quoted:

Note that chrony will give you a factor of 2 or three improvement over 
ntp  in the errors, assuming that the roundtrip is equally split on Linux 
or BSD.

On consumer-grade circuits the assumption about equal round trip is 
unlikely to be valid.

As I said, chrony does a linear regression on the last n offsets. If those n
offsets are all displaced by 1 sec because the outbound packets all suffer a 1 
sec
delay while the inbound ones do not, then the absolute time will be out by 1 
sec. 

This is true for chrony and for ntp, and there is nothing that can be done about
it. 
If the packets occasionally suffer a 1 sec delay but usually are the same as an
inbound, then ntp will probably eliminate those via the clockfilter. Chrony can
also be setup to eliminate packets whose roundtrip times are x times the lowest
value found for the roundtrip, where x is settable in /etc/chrony.conf. which 
will
also eliminate those 1 second guys. 
(ntp's algorithm is stupid because it eliminates 80 % of the packets, even if 
the
excess delays are say 10% of the total delay, and keeps them even if the delay 
is
100 times the minimum if all of the last 8 have been in that boat. chrony's
algorithm uses the minimum value of the delay over long time scales, so that if
random symmetric delay noise increases many valid packets can also be thrown 
out.
)

Asymmetric delays are something that all time systems have trouble with, and at
some level there is nothing that can be done about it. 

Given that problem, one then needs to look at chrony and ntp's use of the data
that is actually collected and ask which makes the best use of that data to
estimate the rate and offset of the local clock. I think that it is clear that
chrony does a far better job. Whether there are situations in which it does a
worse job, I do not know, but have not been able to think of any, but that may 
say
more about me than about chrony or ntp. 

ntp has had the advantage of a long history of testing in a very wide variety of
situations. chrony has been out there for about 10 years, but has not been as
extensively tested in adverse situations. It used to be that chrony also had the
disadvantage that it did not handle leap seconds. (Ie once very few years, it
would suddenly find itself out by a second and have to slew the clock for the 
next
hour or less  to correct that-- if not warned by the leapsecond flag, 
ntp would either step the clock (with the concomitant problems for filesystem 
timing), 
quit entirely, or take many many hours to correct the problem by slewing.
 ie the uncorrected  leapsecond was far less of a problem for
chrony than for ntp) It also did not handle any refclocks. Both of these 
problems
have now been corrected by M Lichvar in the git repository. 
(chrony.tuxfamily.org) 
The other problem is that chrony runs only on Linux or BSD. It does NOT run on
Windows. That would require a pretty extensive rewriting. Curnow got started on
this ( and kept chrony very modular to try to make this easy) but it is still a
big task.   



I hope that David Lord can make some tests, and I await the results with 
interest.

Cheers,
David 

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David J Taylor
 David J Taylor writes:
 On consumer-grade circuits the assumption about equal round trip is
 unlikely to be valid.

 Why would you expect the asymmetry to be worse there than elsewhere?
 -- 
 John Hasler

It's just an impression I had - that consumers get the worst latency and 
most overloaded network equipment, and no direct connection to an 
ultra-high-speed academic network.  But I would love to learn the actual 
figures.

David 

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David J Taylor
Unruh  wrote in message news:kx%gm.50022$db2.12...@edtnps83...
[]
 As I said, chrony does a linear regression on the last n offsets.

[]

Bill,

I think we have seen these remarks about chrony before.

What I was wanting was a yes/no answer (although numbers would be nice) to 
the question:

- is the 2-3 times improvement in the errors affected by the assumption of 
equal round trip?

Perhaps there is no definitive answer?

Cheers,
David 

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread John Hasler
David J Taylor writes:
 It's just an impression I had - that consumers get the worst latency
 and most overloaded network equipment...

Perhaps, but it doesn't follow that they suffer a great deal of
asymmetry.

 ...and no direct connection to an ultra-high-speed academic network.

Of course not, and probably no bleeding-edge switches with packet
buffering, NICs with interrupt coalescing, or experimental routers,
either.  As far as I know round trip symmetry is not a design goal for
any part of the Net.

On the other hand, deep packet inspection _could_ introduce asymmetry.

Seems to me that the dumber the network between me and the server the
more likely I am to see symmetric latentcy.
-- 
John Hasler 
jhas...@newsguy.com
Dancing Horse Hill
Elmwood, WI USA

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David Lord
David J Taylor wrote:
 
 Unruh unruh-s...@physics.ubc.ca wrote in message 
 news:qg_gm.50009$db2.46...@edtnps83...
 David J Taylor 
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid writes:


 David J Taylor
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid wrote in
 message news:%xqgm.126$ym4...@text.news.virginmedia.com...
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

 For those without wide-bandwidth academic connections - those folks on
 cable or ADSL - how good is an equal split round trip assumption?

 David

 Thanks, David, David and Jan.  A few milliseconds is what I had 
 expected,
 so if you are on a consumer line, what implications does that have for
 unruh's comment?

 Cheers,
 David

 Which comment?
 
 The one I quoted:
 
 Note that chrony will give you a factor of 2 or three improvement over 
 ntp  in the errors, assuming that the roundtrip is equally split on 
 Linux or BSD.
 
 On consumer-grade circuits the assumption about equal round trip is 
 unlikely to be valid.
 
 I hope that David Lord can make some tests, and I await the results with 
 interest.

Both fileserver using ntpd and desktop using chrony had only my
local ntp servers as sources so I've restarted both with three
remote sources, one common source at my isp, and alternate
sources from two different sites.

What I'm most interested in is the effect of temperature as it's
one of two periods in year that gets largest temperature
variations and I've already had to restart the servers as ntpd
was unable to keep up with the higher minpoll values I had set.

I'm now not quite sure how best to compare stats from chrony vs
ntpd.


David

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread Unruh
David Lord sn...@lordynet.org writes:

David J Taylor wrote:
 
 Unruh unruh-s...@physics.ubc.ca wrote in message 
 news:qg_gm.50009$db2.46...@edtnps83...
 David J Taylor 
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid writes:


 David J Taylor
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid wrote in
 message news:%xqgm.126$ym4...@text.news.virginmedia.com...
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.

 For those without wide-bandwidth academic connections - those folks on
 cable or ADSL - how good is an equal split round trip assumption?

 David

 Thanks, David, David and Jan.  A few milliseconds is what I had 
 expected,
 so if you are on a consumer line, what implications does that have for
 unruh's comment?

 Cheers,
 David

 Which comment?
 
 The one I quoted:
 
 Note that chrony will give you a factor of 2 or three improvement over 
 ntp  in the errors, assuming that the roundtrip is equally split on 
 Linux or BSD.
 
 On consumer-grade circuits the assumption about equal round trip is 
 unlikely to be valid.
 
 I hope that David Lord can make some tests, and I await the results with 
 interest.

Both fileserver using ntpd and desktop using chrony had only my
local ntp servers as sources so I've restarted both with three
remote sources, one common source at my isp, and alternate
sources from two different sites.

What I'm most interested in is the effect of temperature as it's
one of two periods in year that gets largest temperature
variations and I've already had to restart the servers as ntpd
was unable to keep up with the higher minpoll values I had set.

I'm now not quite sure how best to compare stats from chrony vs
ntpd.

Well, the way I did it was to attach a GPS PPS to the computer and use the 
offset
between it and the system time as a measurement of the accuracy. 
(the gps was NOT used as a source for eitehr ntp or chrony).




David

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread Unruh
David J Taylor david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid 
writes:

Unruh  wrote in message news:kx%gm.50022$db2.12...@edtnps83...
[]
 As I said, chrony does a linear regression on the last n offsets.

[]

Bill,

I think we have seen these remarks about chrony before.

Some have, some have not. I was just putting out there what the difference 
between
ntp and chrony was, so people could make up their own minds. 


What I was wanting was a yes/no answer (although numbers would be nice) to 
the question:

- is the 2-3 times improvement in the errors affected by the assumption of 
equal round trip?

Perhaps there is no definitive answer?

As I tried to emphasise, if the round trip is not symmetric, then neither ntp 
not
chrony can compensate for that lack of symmetry, and the absolute time will be
out. If occasionally it has an assymetric round trip, then ntp will probably
elimate it, and chrony may or may not, depending on how you set up chrony, but
typically chrony will be more sensitive to that asymmetry. 
Eb, say on exactly every 5th query, an extra .3ms is added to the return trip, 
and
lets say that the minimum round trip is .15ms plus or minus .1 ntp will always
throw out those fifth cases. but will have an error around .05 ms. chrony will
not, and without them would have an error of .02ms but with them would have an
error of about .05ms, just as would ntp. Ie, in this case the chrony advantage
would be more or less erased by those asymmetric round trips. 

There is no definative answer. 
It depends on the situation. 
 

Cheers,
David 

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] NTP absolute accuracy?

2009-10-31 Thread David Lord
Unruh wrote:
 David Lord sn...@lordynet.org writes:
 
 David J Taylor wrote:
 Unruh unruh-s...@physics.ubc.ca wrote in message 
 news:qg_gm.50009$db2.46...@edtnps83...
 David J Taylor 
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid writes:


 David J Taylor
 david-tay...@blueyonder.not-this-bit.nor-this.co.uk.invalid wrote in
 message news:%xqgm.126$ym4...@text.news.virginmedia.com...
 Unruh  wrote in message news:34jgm.50898$ph1.36...@edtnps82...
 []
 Note that chrony will give you a factor of 2 or three improvement over
 ntp  in the errors, assuming that the roundtrip is equally split on
 Linux or BSD.
 For those without wide-bandwidth academic connections - those folks on
 cable or ADSL - how good is an equal split round trip assumption?

 David
 Thanks, David, David and Jan.  A few milliseconds is what I had 
 expected,
 so if you are on a consumer line, what implications does that have for
 unruh's comment?
 Cheers,
 David
 Which comment?
 The one I quoted:

 Note that chrony will give you a factor of 2 or three improvement over 
 ntp  in the errors, assuming that the roundtrip is equally split on 
 Linux or BSD.

 On consumer-grade circuits the assumption about equal round trip is 
 unlikely to be valid.

 I hope that David Lord can make some tests, and I await the results with 
 interest.
 
 Both fileserver using ntpd and desktop using chrony had only my
 local ntp servers as sources so I've restarted both with three
 remote sources, one common source at my isp, and alternate
 sources from two different sites.
 
 What I'm most interested in is the effect of temperature as it's
 one of two periods in year that gets largest temperature
 variations and I've already had to restart the servers as ntpd
 was unable to keep up with the higher minpoll values I had set.
 
 I'm now not quite sure how best to compare stats from chrony vs
 ntpd.
 
 Well, the way I did it was to attach a GPS PPS to the computer and use the 
 offset
 between it and the system time as a measurement of the accuracy. 
 (the gps was NOT used as a source for eitehr ntp or chrony).
 

How do you get the time difference between your GPS and system
time?

At the moment there only seems to be 100us between offsets and
apart from this being insignificant I wouldn't know which was
nearer to ntp time.

My adsl connection has also been off already for 30 minutes
after I'd set this up. One of my servers that gets time from
MSF and also has both test systems as sources. Both test
systems also have the common source of my isp's timeserver
so I'm expecting to get something meaningful from that.

I might be able to get GPS to both systems but not for a while.

David

___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions