7 replies
by haileyan
Answer From:
http://expertanswercenter.techtarget.com/eac/knowledgebaseAnswer/0,295199,sid63_gci1053871,00.html
Is there an easy way to reset multiple passwords within a Windows 2000 domain? I have about 2000 accounts that I want to have all reset to a common password and then force the user to change the password on the next logon. QUESTION POSED ON: 22 AUG 2004
QUESTION ANSWERED BY: Paul Hinsberg You can script this pretty easy. Output a list of the names by exporting them from AD. Then you can use a simply FOR statement to reset the accounts. Let's say your text file is names.txt:
FOR /F %I in (names.txt) do NET USER %I [password] /DOMAIN
Replace [password] with the password you want to reset the accounts to. You will of course have to be logged in with domain admin privileges.
create a text file containing the users and passwords like so:
user1, genericpassword
user2, genericpassword
save it as user.txt
use the for command in the command line like so:
for /F "delims=, tokens=1,2" %A in (users.txt) do net user %A %B /domain
Note: You must be the network administrator to change passwords for domain accounts.
Hope this helps.
in the line: "save it as user.txt"
it should have been: "save it as users.txt"
by jkerns
This did the trick! Thank you.
by jkerns
by jkerns
by jkerns
This discussion is closed to new replies.
Trending Windows Forum posts
Sort by Trending