[ntp:questions] Decreasing Frequency Error in Linux 2.6

2009-01-06 Thread Chris
Hello,

I'm currently running an NTP server using a Garmin 18x LVC as a
stratum-0 time source. Before I installed Linux, I used FreeBSD. Its
frequency error was quite low, usually around 1 ppm. This allowed me
to have stable, desirable times such as:

 remote   refid  st t when poll reach   delay
offset  jitter
==
+navobs1.gatech. .GPS.1 u   32   64  377   58.966
2.622   5.055
+ntp-s1.cise.ufl .GPS.1 u   18   64  377   69.260
2.001   1.998
*GPS_NMEA(1) .PPS.0 l5   16  3770.000
-0.001   0.002

Even under heavy load, the offset for FreeBSD always seemed to be
under 20 microseconds.
Now, I'm trying to run a similar time server with Linux 2.6 and
Rudalfo's LinuxPPS patch (or shmpss or gpsd, doesn't really matter to
me).
I've installed Debian Etch (4.0) stable, and recompiled the testing
2.6.28 Linux kernel with Debian patches and the newest LinuxPPS
patch.
At the moment, I'm using the ATOM driver in ntpd and am experiencing
undesirable frequency error and offsets.
According to today's drift file,
Min offset: -68 microseconds, Max offset: 112 microseconds.
Frequency ppm Min: -18.1570, Max: -17.5150.
a sample ntpq output is

 remote   refid  st t when poll reach   delay
offset  jitter
==
+navobs1.gatech. .GPS.1 u   21   64  377   57.631
1.882   2.206
oPPS(0)  .PPS.1 l   10   16  3770.000
-0.018   0.001

Jitter is often as high as 0.006.
It appears there is no difference between LinuxPPS, shmpps, and gpsd
for these timings. Also, this was not tested under load (besides any
normal load for a debian machine).

So, does anyone have any suggestions for reducing frequency error in
Debian (or the linux kernel)?

Also, is there anyway to keep timings low while producing load? I'd
like to run other things on this server, but not at the expense of
time precision.

Thanks for all the support this group has provided me so far via other
posts,
Chris

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread Per Hedeland
In article 9bca36-5p@mail.specsol.com j...@specsol.spam.sux.com writes:
Unruh unruh-s...@physics.ubc.ca wrote:
 j...@specsol.spam.sux.com writes:
 

Have you never heard of calling ntpdate before starting the NTP daemon?
 
 
 uh, ntpdate is severely depricated, and ntpd -g is what is supposed to be
 used. If ntpd -g fails it is a bug.
 

Uhh, lots of mainline 'nix's don't have a -g option to ntpd and still
have ntpdate, e.g. Solaris 10.

FWIW, and still quite irrelevant to the original question, while the
version shipped with Solaris 10 (xntpd actually) is indeed based on
ancient code, it does have a -g option:

# uname -sr
SunOS 5.10
# /usr/lib/inet/xntpd -v
/usr/lib/inet/xntpd: option requires argument -v
usage: /usr/lib/inet/xntpd [ -abdgmx ] [ -c config_file ] [ -e e_delay ]
[ -f freq_file ] [ -k key_file ] [ -l log_file ]
[ -p pid_file ] [ -r broad_delay ] [ -s statdir ]
[ -t trust_key ] [ -v sys_var ] [ -V default_sysvar ]

It's not documented, and may not do exactly what the current version of
-g does, but something pretty close.

--Per Hedeland
p...@hedeland.org

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


[ntp:questions] interpreting the allan deviation graph of the ntp loopstats-file

2009-01-06 Thread Folkert van Heusden
Hi,

Somewhere I read that one can evaluate their ntp-server by creating an
allan deviation graph of the loopstats-file.
Now I succeeded in creating them:
http://keetweej.vanheusden.com/stats/allan-deviation-plots/ using this
octave script: http://www.wraith.sf.ca.us/ntp/allan.oct
But: now what? What do these graphs tell me?


Folkert van Heusden

-- 
Multitail es una herramienta flexible que permite visualizar los log
file y seguir la ejecución de comandos. Permite filtrar, añadir
colores, combinar archivos, la visualización de diferencias (diff-
view), etc.  http://www.vanheusden.com/multitail/
--
Phone: +31-6-41278122, PGP-key: 1F28D8AE, www.vanheusden.com
___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread jimp
David J Taylor david-tay...@blueyonder.neither-this-bit.nor-this-bit.co.uk 
wrote:
 j...@specsol.spam.sux.com wrote:
 []
 You do understand there are lots of environments where it takes an
 act of God to be allowed to replace vendor utilities with self
 compiled versions, don't you?
 
 Not a problem with Windows, fortunately.  G
 
 David

What planet do you people live on?

I have one client that will not even allow Windows critical security
updates to be installed until a extensive formal test is done to
prove the updates won't effect operations.

This is hardly a unique operation.


-- 
Jim Pennino

Remove .spam.sux to reply.

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread David J Taylor
j...@specsol.spam.sux.com wrote:
[]
 What planet do you people live on?

 I have one client that will not even allow Windows critical security
 updates to be installed until a extensive formal test is done to
 prove the updates won't effect operations.

 This is hardly a unique operation.

Well, I can appreciate that makes sense, as I have known some updates to 
affect normal operations, although in those circumstances I used to 
recommend separate PCs for Internet operations.

I don't recall ever seeing a report of NTP causing problems with normal 
operations.

David 

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread Folkert van Heusden
 I don't recall ever seeing a report of NTP causing problems with normal 
 operations.

Sorry for being anal on this but:
Well almost: certain versions of the linux kernel under certain specific
conditions would panic when ntp introduces a leap second.
http://markmail.org/message/dhm5byrbfcarpiet?q=leap+second+list:org.kernel.vger.linux-kernel
Ok it's a bug in the linux kernel but it is only triggered by ntp.


Folkert van Heusden

-- 
Multi tail barnamaj mowahib li mora9abat attasjilat wa nataij awamir
al 7asoub. damj, talwin, mora9abat attarchi7 wa ila akhirih.
http://www.vanheusden.com/multitail/
--
Phone: +31-6-41278122, PGP-key: 1F28D8AE, www.vanheusden.com
___
questions mailing list
questions@lists.ntp.org
https://lists.ntp.org/mailman/listinfo/questions


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread jimp
David J Taylor david-tay...@blueyonder.neither-this-bit.nor-this-bit.co.uk 
wrote:
 j...@specsol.spam.sux.com wrote:
 []
 What planet do you people live on?

 I have one client that will not even allow Windows critical security
 updates to be installed until a extensive formal test is done to
 prove the updates won't effect operations.

 This is hardly a unique operation.
 
 Well, I can appreciate that makes sense, as I have known some updates to 
 affect normal operations, although in those circumstances I used to 
 recommend separate PCs for Internet operations.
 
 I don't recall ever seeing a report of NTP causing problems with normal 
 operations.
 
 David 

Nor would I ever expect to.

The point is LOTS of places have extensive procedures in place that
must be followed before any software on production systems can be
changed, including applying vendor supplied and recommended patches.

While I have free reign to do anything I want with my systems, such is
not the case for many of my client's systems.


-- 
Jim Pennino

Remove .spam.sux to reply.

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread David J Taylor
Folkert van Heusden wrote:
 I don't recall ever seeing a report of NTP causing problems with
 normal operations.

 Sorry for being anal on this but:
 Well almost: certain versions of the linux kernel under certain
 specific conditions would panic when ntp introduces a leap second.
 http://markmail.org/message/dhm5byrbfcarpiet?q=leap+second+list:org.kernel.vger.linux-kernel
 Ok it's a bug in the linux kernel but it is only triggered by ntp.


 Folkert van Heusden

Thanks for that.  I do wish it were easier to test these leap-second 
issues.

David 

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread David J Taylor
j...@specsol.spam.sux.com wrote:
[]
 The point is LOTS of places have extensive procedures in place that
 must be followed before any software on production systems can be
 changed, including applying vendor supplied and recommended patches.

 While I have free reign to do anything I want with my systems, such is
 not the case for many of my client's systems.

Oh, indeed, but I might ask why my client was still running, or had chosen 
to install in the first place, such outdated versions of software, before 
taking on those systems.  But that's life, I suppose.

Cheers,
David 

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


[ntp:questions] ntpd IPv6 support on Windows?

2009-01-06 Thread Dave Hart
I am running Meinberg's Win32 binaries on Windows Server 2003:

ntpd 4.2@beijing-o Sep 01 9:15:56 (UTC+02:00) 2008  (10)

It appears to me there is no support for IPv6 in these binaries.  I'm
guessing the work simply hasn't been done in the reference
implementation to support IPv6 on Windows.  Can anyone confirm that
even if I build my own binaries from source, IPv6 on Windows is not
supported?

Incidentally, their free Windows NTP Time Server Monitor by Meinberg
v1.03a is a nice piece of work.  I use the NTP status tab instead of
scripted ntpq -c peers in a loop, and their loopstats graphing makes
it easy to see how well your timeserver is performing.  If you run ntp
on a platform other than Windows but can access the filesystem via a
mapped network drive, you can use the Statistics tab to graph its
performance by clicking the triple-dot ... button and navigating to
the directory holding the loopstats file.  You may need to enable
stats gathering in ntp.conf first:

statsdir /path/to/store/loopstats/files/
statistics loopstats

Cheers,
Dave Hart

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread jimp
David J Taylor david-tay...@blueyonder.neither-this-bit.nor-this-bit.co.uk 
wrote:
 j...@specsol.spam.sux.com wrote:
 []
 The point is LOTS of places have extensive procedures in place that
 must be followed before any software on production systems can be
 changed, including applying vendor supplied and recommended patches.

 While I have free reign to do anything I want with my systems, such is
 not the case for many of my client's systems.
 
 Oh, indeed, but I might ask why my client was still running, or had chosen 
 to install in the first place, such outdated versions of software, before 
 taking on those systems.  But that's life, I suppose.
 
 Cheers,
 David 

Solaris 10 Update 6 IS the latest release of Solaris and the provided
NTP is nowhere near the latest downloadable version of NTP. 

I would have to check, but I am pretty sure the same is true for HP-UX.

Not everyone runs Linux nor do they usually choose a OS for a rather
obscure feature like NTP.

To get back to the original topic, it seems to me if one really cares
about absolute time, having just one hardware clock is not a very
robust solution no matter what OS or version of NTP is being used.

I have one client that does care and has GPS timeserver appliances
at several sites with all the sites using all the NTP servers as potential
sources so failing a major catastrophe at all sites, there is redundancy.


-- 
Jim Pennino

Remove .spam.sux to reply.

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread Andy Helten
Terje Mathisen wrote:
 Andy Helten wrote:
   
 Unruh wrote:
 
 uh, ntpdate is severely depricated, and ntpd -g is what is supposed to be
 used. If ntpd -g fails it is a bug.
   
   
 Then it is a bug because, as previously mentioned, no command line 
 argument or tinker can disable this behavior.  I suppose the solution is 
 to skip the CLOSETIME check in clocktime() when '-g' is specified.
 

 Andy, I agree totally:

 With no remote reference clocks, only local hardware, said hardware has 
 to skip the sanity checks during that initial -g adjustment.

 Andy, you should go on the ntp.org site and register this as a bug!

 Terje
   

Before creating a bug report I searched the database for CLOSETIME and 
found a bug report had already been opened.  The status is NEW, which 
seemed to imply someone following this email discussion beat me to the 
punch.  However, the existing bug report was opened in April of 2005.  
There is some back-and-forth discussion between the developers 
(including Dave Mills), but clearly there was no consensus on how it 
needs to be fixed and there has been no discussion since August 2005.  
There were some patches submitted that either did not address the exact 
problem we are discussing here or the patches were never accepted.

Not sure what the protocol is for this situation, but it appears the 
original bug report needs a bump:

https://support.ntp.org/bugs/show_bug.cgi?id=417

Andy

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


Re: [ntp:questions] My extra second ...

2009-01-06 Thread Antonio M. Moreiras
The linux kernel bug aparently was found and fixed:

related thread:
http://lkml.org/lkml/2009/1/2/276

bug analysis:
http://lkml.org/lkml/2009/1/2/373

fix:
http://lkml.org/lkml/2009/1/2/415

Antonio M. Moreiras.

Bill Unruh escreveu:
 On Sat, 3 Jan 2009, Danny Mayer wrote:
 
 Unruh wrote:
 George R. Kasica geor...@netwrx1.com writes:

 On Fri, 02 Jan 2009 14:31:34 +0100, Rob van der Putten r...@sput.nl
 wrote:
 Hi there


 Steve Kostecke wrote:

 All my Linux systems had a fine time. None of them locked up / crashed /
 rebooted / etc.

 The kernels involved included:

 2.6.24-etchnhalf.1-amd64
 2.6.18-5-486
 2.6.16-2-486
 2.6.18-5-k7
 2.6.18-4-powerpc
 2.4.16-k7
 What about the hardware (Intel /AMD)?
 Rob:
 Everything in my post above was Intel based, no AMD or otherwise.
 Why in the world would you then have an amd64 kerenl and two k7 kernels,
 and one powerpc kernel? None of those is intel.

 He *never* said that. Those are Steve's systems. The post even includes
 that fact.
 
 Ooops. My mistake-- not reading th  properly
 
 
 Danny

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


Re: [ntp:questions] NTP sever on an isolated Network

2009-01-06 Thread Diego Ramos
Hi Harlan.

Sorry for the late reply, but we had a problem with our modem and we got a
tough time to find another one compatible with my hardware.

I tried what you suggest :

 server 127.127.18.1 minpoll 12 maxpoll 17
 phone atdt913034944774 atdt917195676742


The problem is different now. The ntp.log says: *refclock_open /dev/acts1:
no such file or directory.*

I made a symlink of /dev/acts1 to my /dev/modem, but I still get this error.

Is there anything that I'm missing?

Thanks.

Diego



On Thu, Nov 13, 2008 at 8:55 PM, Harlan Stenn st...@ntp.org wrote:

 Diego,

 Have you seen:

  https://support.ntp.org/bin/view/Support/ConfiguringModemRefclocks

 or

  https://support.ntp.org/bin/view/Support/ModemRefclockUsers
 --
 Harlan Stenn st...@ntp.org
 http://ntpforum.isc.org  - be a member!

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

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


Re: [ntp:questions] ntpd IPv6 support on Windows?

2009-01-06 Thread Danny Mayer
Dave Hart wrote:
 I am running Meinberg's Win32 binaries on Windows Server 2003:
 
 ntpd 4.2@beijing-o Sep 01 9:15:56 (UTC+02:00) 2008  (10)
 
 It appears to me there is no support for IPv6 in these binaries.  I'm
 guessing the work simply hasn't been done in the reference
 implementation to support IPv6 on Windows.  Can anyone confirm that
 even if I build my own binaries from source, IPv6 on Windows is not
 supported?
 

Not yet. It's on my list of things to complete in the near future. There
are two pieces that need to be changed and one of them may be tricky
though I seem to remember that Martin had put something together to help
with this since we need to support people without IPv6 support and don't
have getaddrinfo() and friends available. getaddinfo() is necessary for
IPv6 support. Now's the time to get that in.

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


Re: [ntp:questions] interpreting the allan deviation graph of the ntp loopstats-file

2009-01-06 Thread Danny Mayer
Folkert van Heusden wrote:
 Hi,
 
 Somewhere I read that one can evaluate their ntp-server by creating an
 allan deviation graph of the loopstats-file.
 Now I succeeded in creating them:
 http://keetweej.vanheusden.com/stats/allan-deviation-plots/ using this
 octave script: http://www.wraith.sf.ca.us/ntp/allan.oct
 But: now what? What do these graphs tell me?
 
 
 Folkert van Heusden
 

You need to review the research documents on the ntp.org site or the
Mills book on NTP for details. You can do a google search for allan
deviation and specify site:ntp.org along with the search string.

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


Re: [ntp:questions] ntpd IPv6 support on Windows?

2009-01-06 Thread Dave Hart



On Tue, Jan 6, 2009 at 7:19 PM, Danny Mayer ma...@ntp.isc.org wrote
to questions@lists.ntp.org and me:

 Not yet. It's on my list of things to complete in the near future. There
 are two pieces that need to be changed and one of them may be tricky
 though I seem to remember that Martin had put something together to help
 with this since we need to support people without IPv6 support and don't
 have getaddrinfo() and friends available. getaddinfo() is necessary for
 IPv6 support. Now's the time to get that in.

It sounds like late-binding the required syscalls/APIs with LoadModule
and GetProcAddress is in order.  One way to minimize the source
disturbance when late-binding is to provide your own wrapper
implementations for each function and use a macro to redirect ntp's
calls to the conditionally-available functions through the
corresponding runtime-binding wrappers.  In this case Microsoft has
already done the legwork, including support for the Windows 2000 IPv6
download (which implements these in a different DLL than WinXP and
later).  Quoting from their getaddrinfo documentation at
http://msdn.microsoft.com/en-us/library/ms738520(VS.85).aspx

 begin quote
The getaddrinfo function was added to the Ws2_32.dll on Windows XP and
later. To execute an application that uses this function on earlier
versions of Windows (Windows 2000, Windows NT, and Windows Me/98/95),
then you need to include the Ws2tcpip.h and Wspiapi.h files. When the
Wspiapi.h include file is added, the getaddrinfo function is defined
to the WspiapiGetAddrInfo inline function in the Wspiapi.h file. At
runtime, the WspiapiGetAddrInfo function is implemented in such a way
that if the Ws2_32.dll or the Wship6.dll (the file containing
getaddrinfo in the IPv6 Technology Preview for Windows 2000) does not
include getaddrinfo, then a version of getaddrinfo is implemented
inline based on code in the Wspiapi.h header file. This inline code
will be used on older Windows platforms that do not natively support
the getaddrinfo function.
The IPv6 protocol is supported on Windows 2000 when the IPv6
Technology Preview for Windows 2000 is installed. Otherwise
getaddrinfo support on versions of Windows earlier than Windows XP is
limited to handling IPv4 name resolution.
 end quote

That sounds pretty darned painless, I hope it is indeed that easy for
you.  Now, ask me why I care about IPv6 when it'll apparently be years
before my IPv6 service isn't tunnelled over IPv4 using one lovely hack
or another guaranteed to add overhead and latency.  I don't have a
good answer.  I just want to break and enter into a few ipmasq and NAT
pioneers' homes and disable every telephone ringer.

Dave Hart

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


Re: [ntp:questions] Why can't clocks do inital synchronization?

2009-01-06 Thread Danny Mayer
Folkert van Heusden wrote:
 I don't recall ever seeing a report of NTP causing problems with normal 
 operations.
 
 Sorry for being anal on this but:
 Well almost: certain versions of the linux kernel under certain specific
 conditions would panic when ntp introduces a leap second.
 http://markmail.org/message/dhm5byrbfcarpiet?q=leap+second+list:org.kernel.vger.linux-kernel
 Ok it's a bug in the linux kernel but it is only triggered by ntp.
 

I just saw something about this in the NTP WG from the linux kernel
wranglers who seem to be totally confused about NTP. They should fix the
kernel bug and not start talking about TAI.

Danny

 
 Folkert van Heusden
 

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