created by Tyler Harris

This is a bash script to bulk create LDAP users and add them to a new group. It has been verified via LDAP with eDirectory, but is only intended for testing and troubleshooting purposes. Sometimes you just need a ton of users and would rather not go through the trouble of adding them all manually.


  • Connects to an LDAP server via :389 with specified credentials
  • Creates #ofUsers in a base container: (user1, user2, etc.)
  • Prompts if users should be added to a group
  • Generates two ldifs: add, modify (if group is requested)
  • Uses ldapadd command for creating users
  • Uses ldapmodify command for modifying users (group)
  • For group: adds user to group member with equivalentToMe,
    adds to user’s groupMembership attribute.
2 votes, average: 4.00 out of 52 votes, average: 4.00 out of 52 votes, average: 4.00 out of 52 votes, average: 4.00 out of 52 votes, average: 4.00 out of 5 (2 votes, average: 4.00 out of 5)
You need to be a registered member to rate this post.

Disclaimer: As with everything else at NetIQ Cool Solutions, this content is definitely not supported by NetIQ, so Customer Support will not be able to help you if it has any adverse effect on your environment.  It just worked for at least one person, and perhaps it will be useful for you too.  Be sure to test in a non-production environment.

Leave a Reply

No Comments
By: tdharris
Mar 8, 2017
1:17 pm
Active Directory Authentication Automation Cloud Computing Cloud Security Configuration Customizing Data Breach DirXML Drivers End User Management Identity Manager Importing-Exporting / ICE/ LDIF Intelligent Workload Management IT Security Knowledge Depot LDAP Monitoring Open Enterprise Server Passwords Reporting Secure Access Supported Troubleshooting Workflow