NTPD issue (solved)

Please post any bugs you have found
Post Reply
Message
Author
Nick
Posts: 2
Joined: Sat 22 Dec 2007, 12:11
Location: Pompey, England
Contact:

NTPD issue (solved)

#1 Post by Nick »

I found that installing NTP, although it all appears to work, it doesn't. Querying the server with 'ntpq -pn' produces:

Code: Select all

Servname not supported for ai_socktype
This is caused by the time server port (123) not being declared in Netwrok services file -> '/etc/services'. Fixing this up by adding:

Code: Select all

ntp             123/tcp
ntp             123/udp
sorts it:

Code: Select all

# ntpq -pn
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
 158.152.1.76    192.5.41.40      2 u    1   64    1   23.894  2885134   0.001
 193.62.22.82    .DCFa.           1 u    -   64    1   30.077  2885134   0.001
 195.177.253.180 .INIT.          16 u    -   64    0    0.000    0.000   0.001
Nick

nic2109
Posts: 405
Joined: Mon 01 Jan 2007, 20:24
Location: Hayslope, near Middlemarch, Midlands, England

Re: NTPD issue (solved)

#2 Post by nic2109 »

Nick wrote:I found that installing NTP, although it all appears to work, it doesn't.
May I ask how you installed NTP please? Then, if you could write this all up in a HOWTO, we could all benefit. 8)

Many thanks.

david.d.miller
Posts: 3
Joined: Wed 02 Jan 2008, 00:11

NTPD issue

#3 Post by david.d.miller »

What is the URL for the ntpd download?

User avatar
paulh177
Posts: 975
Joined: Tue 22 Aug 2006, 20:41

#4 Post by paulh177 »

I happened to be looking at ntp when this thread came to my attention.

There's couple of ways to do it.

You could compile from the ntp sources by installing the dev_xxx.sfs file for your version of puppy (see here and here to find out how) and download the source from ntp.org

Or, if you are using puppy 3.x just install a slackware binary using Gslapt (search forum for download of Gslapt)

Unless you are desperate to run a time server or absolute millisecond time accuracy is essential to you, ntpd seems like overkill. After I compiled the whole thing I realised all I really needed from it was ntpdate in my rc.local. So I installed that and deleted the rest.

I also found that /etc/ntp.conf is recreated on each boot (even on a full hd install) so if you customise it the changes are lost ... but i can't find where it gets created (there's a reference to it in rc.network but that's all)

hope this helps

paul
Last edited by paulh177 on Thu 03 Jan 2008, 08:10, edited 3 times in total.

Nick
Posts: 2
Joined: Sat 22 Dec 2007, 12:11
Location: Pompey, England
Contact:

#5 Post by Nick »

Sorry Guys, what with Xmas, I have not been about much.

OK, I am hardened user of GNU/Linux since 1999. I only got Puppy the other week, as I have an old laptop, and needed a fast, light and easy distro that kids can use AND look too great to stop using it. Puppy is IDEAL!

Also I installed to HD, FULL. So I wouldn't know how to help to get it to work on a live CD (because I haven't looked at that yet).

I installed NTPD from source. The ONLY reason I did was due this laptop having a bad BIOS, and sometimes it dies and boots with errors, and date gets set to 01/01/2000 or something silly.

I don't know why Puppy doesn't have the ntp declaration in /etc/services. but I think it may be an oversight.

NTP pages are here:

http://www.ntp.org/

BTW, using ntpdate is OK to sync once at boot but inly if the clock drifts a little, but is really not preferred as a 'time setter' for a few reasons. One is it hammers the time servers, and another is it can screw your system file timestamps if BIOS hwclock is AWOL (i.e. imagine saving a file to disc today, and then tomorrow it is 4 years old... or 4 years in the future?).

Nick

Wolf Pup
Posts: 637
Joined: Fri 28 Apr 2006, 01:37

#6 Post by Wolf Pup »

http://puppylinux.ca/bugs a simple time setter there.
[img]http://img230.imageshack.us/img230/8595/ubd6467dp2.png[/img]
[url=http://www.tinyurl.com/54tu74]Visit The Repository[/url] - Helpful and hard-to-find treats for Puppy 3.
[url=http://www.tinyurl.com/c5a68f]Click Here for Puppy Support Chat, + Helpful Links.[/url]

Post Reply