+ Post New Thread
Page 1 of 3 123 LastLast
Results 1 to 15 of 31
Windows Thread, Bulk update of Active Directory user info in Technical; Slightly different from the usual 'bulk creation' question. I already have my AD users created. However my predecessor did not ...
  1. #1

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,803
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224

    Bulk update of Active Directory user info

    Slightly different from the usual 'bulk creation' question. I already have my AD users created. However my predecessor did not fill in all the information. In paticular i would like to fill in the First Name/Surname/Display Name fields (for ABTutor) and email address (for Moodle LDAP). Any suggestions how to do this?

    Note I do not want to re-create the accounts, just modify them.

  2. #2


    Join Date
    Jan 2006
    Posts
    8,202
    Thank Post
    442
    Thanked 1,032 Times in 812 Posts
    Rep Power
    339
    I use a simple vbscript to run through the ou, and update attributes for each user in the ou
    Code:
    Set objParent = GetObject("LDAP://OU=Year group,OU=address,DC=dot,DC=com")
    
    objparent.Filter = Array("user")
    
    
    
    for each objUser in objParent
    
      'Wscript.Echo "Modifying " & objUser.Get("sAMAccountName")
    
    	objUser.put "mail", objUser.Get("sAMAccountName") & "@email.address.com"
    
    
    	objuser.put "proxyAddresses", "SMTP:" & objUser.Get("sAMAccountName") & "@email.address.com"
    
    	objuser.EmployeeType = "STUDENT"
    
    	objUser.put "UserPrincipalName", objUser.Get("sAMAccountName") & "@address.com"
    
    objuser.Setinfo
    
     
    
        
    
    next
    
    Wscript.Echo "Done ;)"
    Al colleague is writing a scrip that will update UPN's from sims so moodle courses can be automatically created


    edit: just look in hte adsiedit/ldap for the attribute names of fistname,lastname etc
    Last edited by CyberNerd; 14th February 2008 at 10:26 AM.

  3. #3

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,803
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224
    Ok, that'll work fine for email addresses. What about First/Last/Display Names? I have the information in a CSV file currently.

  4. #4


    Join Date
    Jan 2006
    Posts
    8,202
    Thank Post
    442
    Thanked 1,032 Times in 812 Posts
    Rep Power
    339
    objuser.put "middleName"
    objuser.put "givenName"
    objuser.put "sn"
    sirname

    objuser.put "name"
    = displayname ?

    you can find all these in the adsi edit - incase you need some extra fields in future.
    Also with moodle it's worth having some content filter on the email side - any instant messages the student sends through moodle should get caught by the email filter

  5. #5
    fooby's Avatar
    Join Date
    Dec 2005
    Posts
    351
    Thank Post
    0
    Thanked 5 Times in 4 Posts
    Rep Power
    19
    this http://www.wisesoft.co.uk/Products/PasswordControl/ has just been updated to bulk change pretty much any information in activedirectory

    hope this helps

  6. #6

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,803
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224
    Cybernerd, I understand that aspect of it. But like I said, I need to read the information in from a CSV and match it up with accounts based on the login.

    fooby, thanks for the link. I'll try the software as soon as my registration comes through.

  7. #7


    Join Date
    Jan 2006
    Posts
    8,202
    Thank Post
    442
    Thanked 1,032 Times in 812 Posts
    Rep Power
    339
    @Geoff, ok - I guess a vbscript guru is needed. I just pulled that from my collection, rather than my head

  8. #8
    mrtechsystems's Avatar
    Join Date
    Jun 2005
    Location
    Yorkshire
    Posts
    424
    Thank Post
    99
    Thanked 22 Times in 22 Posts
    Rep Power
    25
    Geoff there is a program called hygena

    www.systemtools.com 30 days full evaluation

  9. #9

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,803
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224
    fooby, password control does not give me any way to import extra info into AD, just modify existing settings in bulk.

    mrtech, same problem.

  10. #10
    Wiseman82's Avatar
    Join Date
    Jan 2006
    Location
    North East
    Posts
    48
    Thank Post
    3
    Thanked 14 Times in 11 Posts
    Rep Power
    21
    Quote Originally Posted by Geoff View Post
    fooby, password control does not give me any way to import extra info into AD, just modify existing settings in bulk.

    mrtech, same problem.
    Another recent offering of mine might help though:

    http://www.wisesoft.co.uk/Scripts/di...pt.aspx?id=178

    Password Control/Bulk Modify allows you do base modifications on other attributes - you could set the display name to "firstname, surname" but not to load the first name and surname information from a spreadsheet.

    The VBScript above will allow you to update AD Attributes from a CSV file - hope this helps.

    As a side note I have been thinking of adding another tool to allow users to sync active directory with a database (HR database for example or a spreadsheet). I've also been thinking of adding an import utility (you can always use account management spreadsheet for now). The site and tools are all updated in my spare time - I often have lots of ideas but not enough time to implement them.

  11. #11

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,803
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224
    I will give this a go when I'm at work tomorrow

  12. #12

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,803
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224
    So close. That works for everything apart from changing the cn attribute.

    Code:
    LDAP://CN=T Nicholson,OU=Year10,OU=Pupils,OU=All Users,DC=carrhill,DC=lancs,DC=sch,DC=uk
    
    Change cn from 'T Nicholson' to 'Thomas Nicholson'
    
    Commit Changes: Failed.

  13. #13

    Ric_'s Avatar
    Join Date
    Jun 2005
    Location
    London
    Posts
    7,593
    Thank Post
    109
    Thanked 764 Times in 595 Posts
    Rep Power
    181
    I'm pretty sure that CSVDE will do what you want... I found http://www.computerperformance.co.uk...ogon_CSVDE.htm a useful resource.

  14. #14

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,803
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224
    Do you have a download url for CSVDE?

  15. #15

    Ric_'s Avatar
    Join Date
    Jun 2005
    Location
    London
    Posts
    7,593
    Thank Post
    109
    Thanked 764 Times in 595 Posts
    Rep Power
    181
    Quote Originally Posted by Geoff View Post
    Do you have a download url for CSVDE?
    It's a Windows commandline tool. It should be installed on your DCs already IIRC.

SHARE:
+ Post New Thread
Page 1 of 3 123 LastLast

Similar Threads

  1. Active Directory - Single and Bulk User creation and FREE!!
    By siuko in forum How do you do....it?
    Replies: 39
    Last Post: 20th June 2012, 11:29 AM
  2. Active Directory-Script for Creating Bulk Users
    By calapso in forum How do you do....it?
    Replies: 8
    Last Post: 14th January 2009, 06:32 PM
  3. Replies: 26
    Last Post: 19th May 2008, 11:54 PM
  4. Update Active Directory with mySQL table data?
    By netadmin in forum Windows
    Replies: 8
    Last Post: 30th October 2007, 10:43 PM
  5. Replies: 3
    Last Post: 16th November 2006, 09:55 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •