|
Posted by noname on 11/15/06 09:45
In article <12lko8g7o8nbh4b@corp.supernews.com>,
gordonb.i3g64@burditt.org (Gordon Burditt) wrote:
> >I made a test page that just outputs about 100 date('Y-m-d H:i:s');
> >
> >Occationally (say, 1 out of 30 tries) the time goes backwards by one or
> >two seconds. Like:
> >
> >2006-11-14 07:29:16
> >2006-11-14 07:29:16
> >2006-11-14 07:29:16
> >2006-11-14 07:29:14
> >2006-11-14 07:29:14
> >2006-11-14 07:29:14
> >
> >Or even reloading the page, the 2nd page will show an earlier time than
> >the first page by one or two seconds.
> >
> >It's no big deal. It's just interesting. I wonder, how can this happen?
>
> Is the server time synchronized to anything? NTP tries to avoid large
> jumps like that, but other methods (like maybe "net time" or "ntpdate")
> might not.
I have asked my host. It's the same for time() and microtime(), and it
jumps forwards and back, like this:
This is with date() (time()) (microtime()):
2006-11-14 14:30:56 (1163543456) (1163543456.4591)
2006-11-14 14:30:56 (1163543456) (1163543456.4592)
2006-11-14 14:30:56 (1163543456) (1163543456.4593)
2006-11-14 14:30:56 (1163543458) (1163543458.0658)
2006-11-14 14:30:58 (1163543458) (1163543458.0659)
2006-11-14 14:30:58 (1163543458) (1163543458.066)
2006-11-14 14:30:58 (1163543458) (1163543458.0661)
2006-11-14 14:30:58 (1163543458) (1163543458.0662)
2006-11-14 14:30:58 (1163543458) (1163543458.0663)
2006-11-14 14:30:58 (1163543458) (1163543458.0664)
2006-11-14 14:30:58 (1163543458) (1163543458.0665)
2006-11-14 14:30:58 (1163543458) (1163543458.0666)
2006-11-14 14:30:58 (1163543456) (1163543456.4649)
2006-11-14 14:30:56 (1163543456) (1163543456.465)
2006-11-14 14:30:56 (1163543456) (1163543456.4652)
2006-11-14 14:30:56 (1163543456) (1163543456.4653)
2006-11-14 14:30:56 (1163543456) (1163543456.4654)
Those are 1.6 second jumps. It's like there are two clocks.
Navigation:
[Reply to this message]
|