Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Nov 1999 21:06:28 -0500
From:      Greg Lehey <grog@mojave.sitaranetworks.com>
To:        Jonathon McKitrick <jcm@dogma.freebsd-uk.eu.org>
Cc:        Dan Nelson <dnelson@emsphone.com>, freebsd-questions@FreeBSD.ORG
Subject:   Re: mysterious xntpd
Message-ID:  <19991113210628.48593@mojave.sitaranetworks.com>
In-Reply-To: <Pine.BSF.4.02A.9911111727010.48423-100000@dogma.freebsd-uk.eu.org>; from Jonathon McKitrick on Thu, Nov 11, 1999 at 05:28:52PM %2B0000
References:  <19991111122322.03693@mojave.sitaranetworks.com> <Pine.BSF.4.02A.9911111727010.48423-100000@dogma.freebsd-uk.eu.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thursday, 11 November 1999 at 17:28:52 +0000, Jonathon McKitrick wrote:
> On Thu, 11 Nov 1999, Greg Lehey wrote:
>> On Thursday, 11 November 1999 at 11:03:38 -0600, Dan Nelson wrote:
>>> In the last episode (Nov 11), Jonathon McKitrick said:
>>>> So what makes sense for keeping time on a laptop with a PP connection
>>>> once a day?
>>>
>>> xntpd :)  It can maintain correct time even if it can only contact its
>>> time source for a couple hours each day.  I believe it needs about 1/2
>>> hour of continuous connect time to synch after a disconnect.
>>
>> Fine, but that's a lot longer than ntpdate needs.  In addition, it
>> will keep trying to establish contact, which can be undesirable.
>> ntpdate is the obvious choice for a dialup connection; you can put it
>> in the linkup script and it will set the date even before you know
>> you're connected.
>>
>>>> I tried setting it once, and ended up with GMT (Zulu Time) and it
>>>> took me a while to get the zone right.  Now i just have a little
>>>> script called jtime that i run whenever that calles ntpdate.  Does
>>>> this make sense?
>>>
>>> xntpd and ntpdate both set the time in the same way.  You must have
>>> had some other timezone problem.
>>
>> Right, this issue has nothing to do with ntp.  Check your
>> /etc/localtime file.  It should be a copy of your local time zone file
>> in the /usr/share/zoneinfo hierarchy.
>
> I have a one-line script that i call from root when i am connected.  To
> run this command or ntpdate directly, all i need to do is include that
> line in ppp.linkup?  I thought ppp.linkup was commands specific to ppp?
> How do i distinguish calls to an external command?

You can include shell commands in ppp.linkup by preceding them with an
exclamation mark.  See /usr/share/examples/ppp/ppp.linkup.sample:

  #You may want to execute a script after connecting.  This script can do
  # nice things such as kick off "sendmail -q", "popclient my.isp" and
  # "slurp -d news".  It can be passed MYADDR, HISADDR and INTERFACE
  # as arguments too - useful for informing a DNS of your assigned IP.
  #
  # You may also want some sound effects....
  #
  pmdemand:
   !bg /etc/ppp/ppp.etherup.pmdemand
   ! sh -c "cat /etc/ppp/linkup.au >/dev/audio"

Greg
--
When replying to this message, please copy the original recipients.
For more information, see http://www.lemis.com/questions.html
Finger grog@lemis.com for PGP public key
See complete headers for address and phone numbers


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19991113210628.48593>