Account Expired ??

P

Planz

Not sure why (yet) but all of the users accts are expired with a date of
Sept 6 2003
Anyone ever have this problem? And what was the fix?

Better yet how do i do a mass option to set all the users account expired
option to 'Never' ?
 
R

Robbie Allen

Can't say I've heard of that before. How were the accounts initially
created?

You could use this command to reset them:
C:\> for /F "usebackq delims=""" %i in (`dsquery user
"ou=myusers,dc=test,dc=local" -scope onelevel`) do dsmod user -acctexpires
never %i

Replace ou=myusers,dc=test,dc=local with the OU your users are in.

Or if you want to do it via a script, you could combine these two:
http://rallenhome.com/books/adcookbook/src/06.26-set_account_expiration.vbs.txt
http://rallenhome.com/books/adcookbook/src/06.05-modify_multiple_users.vbs.txt

Robbie Allen
Author of "Active Directory Cookbook" (O'Reilly)
http://www.rallenhome.com/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top