AD User Attribute Updater homeDirectory attribute

Anything VBScript-related, including Windows Script Host, WMI, ADSI, and more.
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
User avatar
Posts: 1
Joined: Wed Jul 11, 2012 4:43 am

AD User Attribute Updater homeDirectory attribute

Post by Clever1 »

This is my first post so I figured I'd throw out something that was interesting while I learned how to format the code in my posts....

Be Warned: Bulk editing of Active Directory is not to be taken lightly.

This script changes the AD User attribute homeDirectory but can easily be tweaked to find and replace AD attribute properties.

I know lots of people have attribute changers but this puts a bunch of pieces together. It will traverse (recurse recursive) all of your OU's and all of your CN's. It can bulk target and replace any part of the Home Dir path.

People may say something like this is not required, you can simply select all of your users and then do bulk edit from AD using %USERNAME%. Trust me, that doesn't scale for crap and assumes many thing s like %USERNAME% is the name of a user home dir.

Have you ever had to recover from an ADUC bulk edit of 85K user where your bulk edit only got 95% of the users changed to the proper value becuase user account names changed when they got married or some admin 10 years ago tried to invent his own naming convention for home dirs.

Then go back and try and figure out what the home directory was before you changed it for a couple hundred users.

That pretty much sums up all the key words and phrases that somebody may google to find this script... If you read the whole thing, wow your patient.
AD_Home_Dir_Path_Change_pub.txtClever12012-07-11 12:00:54