Link to home
Start Free TrialLog in
Avatar of enzerj
enzerj

asked on

How to automatically move users from OU-A to Group-A

I need to find a way to automatically move users from organizational unit "A" into security group A. Anytime a new user gets created in OU-A, i have to manually add them to group-A. Can we automate this?

Thanks!
Avatar of smashpmk712
smashpmk712

You can setup a "template" user just like a standard user and add them to group-A and then just copy the user account every time you want to create a new user.
Avatar of enzerj

ASKER

I cannot do that because all users in OU-A get automatically created from an online portal.
Do you have control over the online portal? IE can you change how the user is created from the portal?
ASKER CERTIFIED SOLUTION
Avatar of steezy
steezy

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
You'll need to edit the names and paths to the OU and the Group below:

dsquery user "OU=OU-A,DC=contoso,DC=com" | dsmod group "CN=Group-A,CN=Users,DC=contoso,DC=com" -addmbr