Re: Time slowly goes out of sync Cygwin+windows+psotgres

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Aaron <aarmel(at)netagi(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Time slowly goes out of sync Cygwin+windows+psotgres
Date: 2002-08-29 14:14:34
Message-ID: 26510.1030630474@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Aaron <aarmel(at)netagi(dot)com> writes:
> Is postgres calculateing the time itself or reading of the machines clock?

Postgres just asks the OS what time it is. I think you have an
off-speed system clock crystal (lots of PC-grade hardware will
gain or lose 10 minutes/month :-().

I don't know what test you are using to convince yourself that the OS
time is correct when Postgres' time is different --- but I'll bet lunch
you made a mistake.

One other thing to watch for is that "SELECT now()" returns the time as
of the start of the current transaction. If you said "begin" and then
waited ten minutes you could get a 10-minute discrepancy. I doubt you
did that, but it's something to be aware of.

regards, tom lane

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Tom Lane 2002-08-29 14:17:06 Re: Createlang problem.
Previous Message Gaetano Mendola 2002-08-29 14:06:40 Re: Errors with pg_dump