Hi,
Yesterday i shows you how to create a user group in "Active Directory". Now lets today add members to that user group using powershell.
Lets Start.
Make sure you have "RSAT" installed on you laptop.
Now Import the Active Directory module.
Import-Module ActiveDirectory
..
ok, Module is imported,,
we are going to use Add-ADGroupMember cmdlet.
so we have a user group name as "Singers" which currently have no members.
i am am planning to add "Michal Jackson" and "Rickey Martin" to the group.
the command is below. Add-ADGroupMember and then Name of the Group and after that {SamName} name of the users delimitated by comma. and you can also provide -Server name if you want.
Add-ADGroupMember Singers Ricky.martin,Michael.jackson -Server "LocalDC"
our command run successfully now lets check the Group see if our users are added to it..
Bingo !! All DOne ...
Thanks for reading.
Thanks
Aman Dhally
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.