ADSI Recommendations?

I’m looking around this week, because I have 2 big goals at work and no real resources to address them.

  1. I have to redirect the home folders for >500 Active Directory user accounts.
  2. I need to add departmental locations/addresses to all of these accounts.

The thing is, I don’t know jack about scripting AD or much WMI so I would really like some sort of tool to help me accomplish this easily. Worse, I don’t have any sort of budget available to purchase software. The suggestions I have so far are:

  • ADModify.NET
  • Apollo AD

Anybody else want to weigh in here?

One Response to “ADSI Recommendations?”

  1. mmunem Says:

    A rather belated comment here! I’ve used the following script and it’s worked perfectly.

    ‘ This code sets the home drive of all users under a container
    ‘ to be on a file server where the share name is the same as the user’s
    ‘ sAMAccountName.

    ‘ —————————————————————
    ‘ From the book “Windows Server Cookbook” by Robbie Allen
    ‘ ISBN: 0-596-00633-0
    ‘ —————————————————————

    set objParent = GetObject(“LDAP://”)
    objParent.Filter = Array(“user”)
    for each objUser in objParent
    Wscript.Echo “Modifying ” & objUser.Get(“sAMAccountName”)
    objUser.HomeDirectory = “\\\” & _
    objUser.Get(“sAMAccountName”)
    objUser.SetInfo
    next

    (Source: http://techtasks.com/code/viewbookcode/853)

    By now you’re probably know more about scripting… but parentdn is the containter/OU where the accounts are. This, you can get from adsiedit.msc under I think the distinguishedname attribute for the container. “samaccountname” is the logon name.

    Thanks,
    Mohammed
    http://www.itsworking.co.uk/blog

Leave a Reply

You must be logged in to post a comment.