Raveendran said:
Suppose if I want to change the administrator password on
more than 500 machines is it possible to do the same by
running some scripts. If yes please help me that from
where I can do it. Can I do it using logon scripts or any
other options are available?
Hi
As long as the computers are members of an Active Directory domain:
You could do it in a computer startup script (with a GPO) that runs as
part of the boot up process (before the user logs in). It runs under the
system context and has admin rights.
To avoid users being able to read the script where the password is
stored, grant read access only for the AD group "Domain Computers"
to the script file.
As long as the Administrator account name is "Administrator", this
vbscript will set the password on the account:
'--------------------8<----------------------
sNewPassword = "testpassword"
Set oWshNet = CreateObject("WScript.Network")
sComputer = oWshNet.ComputerName
On Error Resume Next
Set oUser = GetObject("WinNT://" & sComputer & "/Administrator,user")
oUser.SetPassword sNewPassword
oUser.SetInfo
On Error Goto 0
'--------------------8<----------------------
If you want to change the password instead of setting it (but this
means you will need to be sure that you know the old password on
all the computers), use oUser.ChangePassword instead of
oUser.SetPassword, like this:
oUser.ChangePassword "old pwd here", sNewPassword