Hi guys,

I am writing a script that needs to update the time before attempting to join a domain (via sysprep). The problem is that if I just issue the Time command the local admin account doesn't have the domain privileges to access the time server or in this case any time server on the domain. I’m converting an existing Batch script that used the follwing technique to get around the problem:

Code:

rem ** Establish User permissions with rights on the xxx domain **

Net use \\%DOMAIN_CONTROLLER% %DOMAIN_USER_PASSWORD% /user:%CURRENT_DOMAIN%\%DOMAIN_USERNAME%

Cls

rem ** Set time **

Net TIME /DOMAIN:%CURRENT_DOMAIN% /Set



I have roughed up a KiXtart version of the same but have not tested it.. I suspect that it will not work.

Code:

; ** Establish User permissions with rights on the xxx domain **

Use "\\"+$DOMAIN_CONTROLLER /user:$LOGON_DOMIAN+"\"+$DOMAIN_USERNAME /password:$DOMAIN_USER_PASSWORD

CLS

; ** Set Time and Date**

SetTime $LOGON_DOMIAN



Is their an equivalent or more elegant method under KiXtart?

(running V4.5)