Solved

Syncronise Time

Posted on 2006-07-20
22
409 Views
Last Modified: 2010-05-18
Hi All,

Our servers have their time set manually.  I've been asked to put together an automated method.

Having done a bit of reading i believe using an NTP Server is best method.


Any suggestions on what is the best route to take.



Thanks
D
0
Comment
Question by:detox1978
  • 10
  • 9
  • 3
22 Comments
 
LVL 17

Accepted Solution

by:
John Gates earned 500 total points
ID: 17146705
If you have a Windows 2003 domain and an Internet connection then on the PDC emulator you can issue:

net time /setsntp:<Server IP>

You can get the <Server IP > from the ntp server list here:

http://ntp.isc.org/bin/view/Servers/WebHome

Then just make sure all the servers and clients are running the windows time service (By default they are) then all domain members will synch time with the pdc emulator.  In a domain model the PDC role holder is the only server that can synch with an outside time source.

Hope this helps!
-D-
0
 
LVL 13

Expert Comment

by:rhickmott
ID: 17146715
Set up a Scheduled Task ( Control Panel > Scheduled Tasks )

Execute the Instruction

"net time /setsntp:time.windows.com"

Set it something like 2am Daily.

It will Sync Every Day then with the NTP Server of your choice.
0
 
LVL 17

Expert Comment

by:John Gates
ID: 17146720
Oh yeah, If you are not in a domain model then you can issue that command on each server seperately.


0
 
LVL 13

Expert Comment

by:rhickmott
ID: 17146763
Sorry you beat me by one minute :)

We have 4 servers none of them are in a domain one issues a NTP query on a daily basis

net time /setsntp:time.windows.com

and the other servers just sync there time off this server 5 minutes after by

net time //main-server /SET /YES
0
 
LVL 2

Author Comment

by:detox1978
ID: 17153349
Thanks for the suggestions;

I'm running a windows 2000 / 2003 mixed domain model and the PDC Emulator is a 2003.

If I run "net time /setsntp:time.windows.com" on the PDC Emulator, how do i tell the servers to use the PDC emulator for their time?
0
 
LVL 13

Expert Comment

by:rhickmott
ID: 17153415
NET TIME \\COMPUTERNAME /SET /YES

That will set the local machine to sync time with \\computername (in this case your PDC emulator)
0
 
LVL 17

Expert Comment

by:John Gates
ID: 17155370
Actually you should not need to do anything.  The servers will get time from the PDC Emulator because it advertizes itself as the source.

On the servers do:

net time /querysntp

You will see that the PDC role holders name and the time will be displayed.  It is handeled by Kerberos.

-D-
0
 
LVL 2

Author Comment

by:detox1978
ID: 17311042
Hi guys,


Sorry for the slow reply - had to work on other projects.


I've had a quick look on a few of the servers taht are out of sync and they are not currently pointing to the PDC Emulator?


Any thoughts on why?



D
0
 
LVL 2

Author Comment

by:detox1978
ID: 17311065
also, if the servers aren't pointing to the PDC, what is the command to re-point them?
0
 
LVL 17

Expert Comment

by:John Gates
ID: 17311169
net time /setsntp:<pdcname>
0
 
LVL 2

Author Comment

by:detox1978
ID: 17318060
By default within a domain environment the snmp should be set to the PDC emulator.  

This is not the cause in our domain a few point to a different DC, alot point to time.windows.com, and some say "This computer is not currently configured to use a specific SNTP server".


Is there a reason for this, and is there a command to set the server back to default - i.e. it PDC emulator?


I know "net time /setsntp:<pdcname>" will set the snmp, but I would prefer it was set by AD.


Thanks

0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 17

Expert Comment

by:John Gates
ID: 17318131
Well you are asking a loaded question....  If your domain is configuration is correct that would be the case.  

When you type in net time on your servers what is displayed?

Does it return something of this nature:

Current time at \\<domain controller> is <date> <time>

If that is what is returned then your system is working fine.  Even though another time source is chosen the only domain member allowed to go to an outside time source for sync is the pdc role holder.

-D-
0
 
LVL 2

Author Comment

by:detox1978
ID: 17318658
ah, ok.....


so the servers that have time.window.com set up as their snmp - do they just keep their time?


Also, is there a way to reset the snmp so it looks for the PDC emulator?
0
 
LVL 17

Expert Comment

by:John Gates
ID: 17318894
when you typed net time on the servers did it return the pdc emulators name and the time?  If so disregard the time.windows.com and everything is set correctly.  If you typed in net time and it returned:

Current time at time.windows.com is <date> <Time> then there is another issue.


-D-
0
 
LVL 2

Author Comment

by:detox1978
ID: 17324640
They all return a different server, which points to the PDC Emulator.  I've tested the time and that checks out ok...


So what is the sntp used for?
0
 
LVL 17

Expert Comment

by:John Gates
ID: 17325597
Good.  The sntp is to set the PDC emulator to an outside time source.  If all your times are correct then everything is a go.

-D-
0
 
LVL 2

Author Comment

by:detox1978
ID: 17325884
cool,


so am I correct in saying the SNTP setting is only used on a PDC Emulator in a domain model.


0
 
LVL 17

Expert Comment

by:John Gates
ID: 17325913
The setsntp setting to an outside timesource only, yes.
0
 
LVL 2

Author Comment

by:detox1978
ID: 17332503
Cheers.  you've been a great help.... :O)
0
 
LVL 2

Author Comment

by:detox1978
ID: 17333223
Another quick question.


In another domain we manage the PDC emulator has an SNTP value of time.microsoft.com; and when i type net time it returns another servers name (not microsoft).


Do you know where this server will be getting it's time?
0
 
LVL 2

Author Comment

by:detox1978
ID: 17333345
Also, do you know where i can view the correct time including seconds online?


Thanks again.

0
 
LVL 17

Expert Comment

by:John Gates
ID: 17333392
What server is being named?  

Here is a list of public time servers:

 http://ntp.isc.org/bin/view/Servers/WebHome
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

I have never ceased to be amazed how many problems you can encounter on a fresh install of a Windows operating system.  This is certainly case in point& Unable to complete ANY MSI installation.  This means Windows Updates are failing and I can't …
Numerous times I have been asked this questions that what is it that makes my machine log on so slow, there have been cases where computers took 23 minute exactly after taking password and getting to the desktop. Interesting thing was the fact th…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

708 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

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now