Solved

synchronizing clocks on diff. machines

Posted on 1998-08-05
7
353 Views
Last Modified: 2013-12-16
I have a bunch of different machines running different OS's
and I was wondering if there's an easy way of synchronizing
all the clocks and keeping them synchronized.  Or perhaps is
there a way for one machine to "broadcast" the time to all
others?
0
Comment
Question by:ladioss
7 Comments
 
LVL 84

Expert Comment

by:ozo
ID: 1812565
do all the OS's support timed?
0
 
LVL 2

Expert Comment

by:lucidity
ID: 1812566
NT servers will respond to the "net time" command.

net time \\NTSName /set /yes

I don't know if UNIX will make this call, anyway, I put that in my start up to synch to the server.

0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 1812567
lucidity, why do you post M$ proprietary answres in a UNIX topic?
It's even just half the trouth, it won't work this way in a default M$ setup.

timed (as ozo said) is the solution, available for most M$ products too ;-))
0
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

 

Author Comment

by:ladioss
ID: 1812568
I'm not familiar in that area...how would i get it to work if it
supports timed?  These machines are not running NT, but unix
os's.
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 1812569
timed works in master-slave mode (IRIX also supports primary and secondary masters).

You start timed as master on one machine, and as slave on all others. timed can be configured via options how to synchronize, see man-page for details.
Be prepared that it has different options on different platforms.
0
 

Accepted Solution

by:
almasy earned 100 total points
ID: 1812570
For all of your Unix systems I would recommend setting up a root cron job (use "crontab -e" as root) that runs the "rdate" command periodically to query the time from a common host.

The syntax for "rdate" is:

    rdate -s hostname

Where "hostname" is the name of the machine to query, and the "-s" parameter may not be needed for some flavors of Unix (it can be left off for Solaris and SunOS).

For internet-connected systems there are a number of public machines to query.  The one I usually use is "time.mit.edu", so the crontab entry that I have set up under Solaris is:

    45 4 * * * /usr/bin/rdate time.mit.edu > /dev/null

Which updates the system time at 4:45am each day.

It may also be desirable to invoke rdate from the startup scripts on each machine and/or to increase the frequency of cron invocations, if you're concerned about the clocks always being synchronized.
0
 

Author Comment

by:ladioss
ID: 1812571
Actually, i already have it answered by ozo.  Timed was the answer and I have it working on all 6 different OS's now even
though it was a pain with all the different options on the different platforms like ahoffmann said.  sorry that i couldn't give you the points though, ozo.

thanks to all!
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Samsung memory install did'nt recognize by new hardware 5 27
sudo logging 5 91
Using gawk to read and manipulate multiple texts from a file 1 59
MarkLogic 1 79
My previous tech tip, Installing the Solaris OS From the Flash Archive On a Tape (http://www.experts-exchange.com/articles/OS/Unix/Solaris/Installing-the-Solaris-OS-From-the-Flash-Archive-on-a-Tape.html), discussed installing the Solaris Operating S…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question