O'Reilly logo

Solaris™ Operating Environment Boot Camp by Dominic Butler, David Rhodes

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Rdate

To get around the problems of manually setting the date on every system, a utility named rdate can be used. This will set the local system time to that of a specified remote machine. For example, to set helium to the same date as hydrogen we would run:

helium# rdate hydrogen
Sun October 22 17:30:00 GMT 2002
hydrogen#

To automate this procedure, we could nominate a machine to be our “time server.” As explained above, we have chosen hydrogen for this task. First, we set the correct time on hydrogen. Next, we run rdate on a regular basis, by adding an entry to the root crontab. The redirection will ensure that we don't receive the output as mail every time cron runs:

 helium# crontab -l | grep rdate 0 4,12,20 * * * rdate timeserver > /dev/null ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required