Question Locked

Net Time script does not seem to work

0 helpful
2 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

We have this as part of the logon script to sync everyone's clock to a server:
Net Time \\server1 /set /yes

The server runs on NT4, while the clients are on XP/2000/9x.

Problem:
The script does not seem to work on Windows 2000/XP computers as they log on. Do the end users have to have administrator's right in order for the script to take effect? We tried the same command in CMD (with users' logon)and still wouldn't work.
If that's the case, is there a way to make the script work without granting users admin right?

Thanks for all input.

2 replies

by locolobo

I think the logon script has to be in C:\Winnt\system32\Repl\Import\Scripts on the server. We named ours logontime.bat. I'm assuming that in User Manager you have entered the logon script name under each profile. Below is the contents of logontime.bat:

if exist c:\winnt\system32\net.exe c:\winnt\system32\net time \\salnt4 /set /y
if exist c:\windows\system32\net.exe c:\windows\system32\net time \\salnt4 /set /y

I can't remember why we didn't set path on each machine, but just using "Net Time" wasn't working for us either. The 2 ifs cover the case if the machine is XP or NT.

Hopefully this works for you.

This discussion is closed to new replies.