Thank you both for the quick replies.

The answer to my problem is htpdate. I was searching for such an utility for
quite some time. I still have one problem, though. When installing Gentoo, I
probably chose the USA as my location. However, I'm located in CET (that is,
GMT+1). From htpdate, I receive the following output:

localhost liviu # /usr/sbin/htpdate -dq -P PROXY_ADDRESS:PROXY_PORT
www.linux.org www.opera.com pool.ntp.org
www.linux.org 03 Sep 2007 07:32:19 GMT (0.477) => -24738
www.linux.org 03 Sep 2007 07:32:20 GMT (0.325) => -24738
www.opera.com 03 Sep 2007 07:32:21 GMT (0.119) => -24738
www.opera.com 03 Sep 2007 07:32:22 GMT (0.117) => -24738
pool.ntp.org 03 Sep 2007 07:32:22 GMT (0.134) => -24738
pool.ntp.org 03 Sep 2007 07:32:23 GMT (0.072) => -24738
#: 3, mean: -24738, average: -24738.000
Timezone: GMT-5 (EST,EST)
Offset -24738.000 seconds

For some reason, it persistently considers my timezone EST (Eastern Standard
Time, GMT-5). I reconsidered Gentoo's localization guide and now
/etc/cond.d/clock contains these two options:

localhost liviu # nano /etc/conf.d/clock
[..]
CLOCK="local"
TIMEZONE="Europe/Berlin"
[..]

I also added TZ="Europe/Berlin" to both user and
root ~/.bash_profile. And still, htpdate wants to synchronize my clock to EST.

Any ideas on how to make htpdate think that I'm actually in the EU instead
of the US? There was no info on the way it treats timezones, neither in the
man page, nor on their site. I did find in their changelog: 0.6.1 ----- -
Code clean up, use global variable 'timezone'. However, running it under new
env gives me yet again the time synced to EST:

localhost liviu # timezone="GMT+1" OR TIMEZONE="CET" htpdate -dq -P
PROXY_ADDRESS:PROXY_PORT www.linux.org www.opera.com pool.ntp.org
[..]
Timezone: GMT-5 (EST,EST)
Offset -24738.000 seconds


Regards,
Liviu

On 9/2/07, Arturo 'Buanzo' Busleiman <[EMAIL PROTECTED]> wrote:
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA512
>
> * net-misc/htpdate
>      Available versions:  ~0.9.2 0.9.3 1.0.0
>      Homepage:            http://www.clevervest.com/htp/
>      Description:         Synchronize local workstation with time offered
> by remote webservers
>
>
>


-- 
Liviu

Reply via email to