beautypg.com

Safely updating local system clocks – HP NonStop G-Series User Manual

Page 16

background image

HP NonStop Time Synchronization User’s Guide

Page 16 of 81

Thu Jul 12 18:06:52 UTC 2007

On Linux, you can also use the date and date –u commands as described above:

/tmp > date

Thu Jul 12 12:08:48 CDT 2007

/tmp > date -u

Thu Jul 12 17:08:50 UTC 2007

On Windows, double-click the clock in the system tray to check time settings.

Once you have determined how your local clock is set up, you can configure TimeSync
accordingly. Again, see

Process Options

for more information on setting up the

GMTOffset value for your system if necessary.

Safely Updating Local System Clocks

A common problem in attempting to synchronize clocks is that some time changes can
adversely impact applications that are running on the system. This is particularly true in
two different cases:

1. A drastic time change that causes the clock to jump by a large amount, for example

setting the system clock ahead by an hour. This is problematic because many
applications have some notion of real time and rely on it for scheduling tasks, tracking
progress, and measuring throughput. A sudden large jump in time can wreak havoc
with those activities. For example, an application might have a list of tasks that are to
be initiated at certain times of day. A sudden change in the system clock may cause
some of these tasks to be skipped, or to be invoked in a burst of activity while the
application tries to “catch up” for the time that was missed.

2. Setting the system clock back by any amount of time. This is a particularly

troublesome thing to do because many applications assume that time will never move
backward, and are not designed to handle cases of a given time repeating itself. For
example, an application might rely on the system clock for generating a unique ID for
a transaction, or for generating a unique key for a database record. If the system clock
is set back as part of an effort to synchronize time, there exists a very real possibility
that those same “unique” IDs or keys could be generated again, which in turn could
result in data loss or corruption.

TimeSync addresses both of these issues and lets you tailor its behavior through various
configuration options.

To prevent sudden drastic changes in time, TimeSync can be configured to “drift” clock
changes in slowly over a longer period, thereby eliminating jumps in time that can be
problematic for applications.

This manual is related to the following products: