Logon Script - Synchronizing Time with a Nt 4.0 PDC 
Author Message
 Logon Script - Synchronizing Time with a Nt 4.0 PDC

I am developing a login script that includes synchronizing the local users
clock with our PDC(NT4). We used to do this using a batch file, however I am
hoping that someone can shed some light on how to accomplish this using our
VBScript through the WSH. I would prefer not having to call on our existing
batch file to run to do this but rather doing it entirely through the script
if possible. Any help out there for a busy sysadmin?

Eric :)



Wed, 13 Aug 2003 10:32:17 GMT  
 Logon Script - Synchronizing Time with a Nt 4.0 PDC

Quote:

> I am developing a login script that includes synchronizing the local
> users clock with our PDC(NT4). We used to do this using a batch file,
> however I am hoping that someone can shed some light on how to
> accomplish this using our VBScript through the WSH. I would prefer not
> having to call on our existing batch file to run to do this but rather
> doing it entirely through the script if possible. Any help out there
> for a busy sysadmin?

> Eric :)

The best solution I know is ...

  CreateObject("Wscript.Shell)_
    Run "net time \\server /set /y", 0

Same as with a batch, but no batch required.

Tom Lavedas
-----------
http://www.pressroom.com/~tglbatch/



Wed, 13 Aug 2003 11:41:02 GMT  
 Logon Script - Synchronizing Time with a Nt 4.0 PDC
Hi Tom, that's what I was thinking about using but wondering if there was a
different function :)
Thanks for your help

Eric

Quote:

> > I am developing a login script that includes synchronizing the local
> > users clock with our PDC(NT4). We used to do this using a batch file,
> > however I am hoping that someone can shed some light on how to
> > accomplish this using our VBScript through the WSH. I would prefer not
> > having to call on our existing batch file to run to do this but rather
> > doing it entirely through the script if possible. Any help out there
> > for a busy sysadmin?

> > Eric :)

> The best solution I know is ...

>   CreateObject("Wscript.Shell)_
>     Run "net time \\server /set /y", 0

> Same as with a batch, but no batch required.

> Tom Lavedas
> -----------
> http://www.pressroom.com/~tglbatch/



Wed, 13 Aug 2003 13:01:29 GMT  
 Logon Script - Synchronizing Time with a Nt 4.0 PDC
Hi All,

 one annotation:If the client is NT, the "normal" user don't have the
privilege to set date and time. One has to be admin or member of the "power
users" group (at least so far as I remember). For that reason, we always use
the timeserv from the NT Resource Kit (a service must be installed by
admins, so we put it in the inital installation).

Best regards,
Manfred Braun

(Private)
Lange Roetterstrasse 7
D68167 Mannheim
Germany


(Remove the anti-spam-underscore to mail me!)


Quote:
> Hi Tom, that's what I was thinking about using but wondering if there was
a
> different function :)
> Thanks for your help

> Eric



> > > I am developing a login script that includes synchronizing the local
> > > users clock with our PDC(NT4). We used to do this using a batch file,
> > > however I am hoping that someone can shed some light on how to
> > > accomplish this using our VBScript through the WSH. I would prefer not
> > > having to call on our existing batch file to run to do this but rather
> > > doing it entirely through the script if possible. Any help out there
> > > for a busy sysadmin?

> > > Eric :)

> > The best solution I know is ...

> >   CreateObject("Wscript.Shell)_
> >     Run "net time \\server /set /y", 0

> > Same as with a batch, but no batch required.

> > Tom Lavedas
> > -----------
> > http://www.pressroom.com/~tglbatch/



Thu, 14 Aug 2003 03:20:08 GMT  
 Logon Script - Synchronizing Time with a Nt 4.0 PDC
Hi Manfred, nearly all our clients are Win9x stations, only 20 are win2k and
they have power user access and the script does appear to work

Eric

Quote:
> Hi All,

>  one annotation:If the client is NT, the "normal" user don't have the
> privilege to set date and time. One has to be admin or member of the
"power
> users" group (at least so far as I remember). For that reason, we always
use
> the timeserv from the NT Resource Kit (a service must be installed by
> admins, so we put it in the inital installation).

> Best regards,
> Manfred Braun

> (Private)
> Lange Roetterstrasse 7
> D68167 Mannheim
> Germany


> (Remove the anti-spam-underscore to mail me!)



> > Hi Tom, that's what I was thinking about using but wondering if there
was
> a
> > different function :)
> > Thanks for your help

> > Eric



> > > > I am developing a login script that includes synchronizing the local
> > > > users clock with our PDC(NT4). We used to do this using a batch
file,
> > > > however I am hoping that someone can shed some light on how to
> > > > accomplish this using our VBScript through the WSH. I would prefer
not
> > > > having to call on our existing batch file to run to do this but
rather
> > > > doing it entirely through the script if possible. Any help out there
> > > > for a busy sysadmin?

> > > > Eric :)

> > > The best solution I know is ...

> > >   CreateObject("Wscript.Shell)_
> > >     Run "net time \\server /set /y", 0

> > > Same as with a batch, but no batch required.

> > > Tom Lavedas
> > > -----------
> > > http://www.pressroom.com/~tglbatch/



Thu, 14 Aug 2003 14:10:25 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. Synchronizing time with my PDC

2. NT 4.0, user groups, PDC's, BDC's and IsMember

3. Permission Denied in NT 4.0 Logon Script

4. Send "Synchronize Entire Domain" to PDC

5. How to synchronize date and time in log on script

6. Problems Installing Windows Script 5.0 and Windows Script Host 2.0 Beta on Windows NT 4.0

7. WSH on NT 4.0 Server without IE 4.0 (5.0)

8. WSH Script in NT Logon Script

9. Determing Groups in VB Script NT 4.0

10. How can I read NT40 Global Groups in VB SCRIPT on NT 4.0

11. synchronize time

12. Restart NT server 4.0 from script

 

 
Powered by phpBB® Forum Software