http://windowstricks.in/

We've moved from ganesh-windowstricks.blogspot.in to windowstricks.in,please update your feeds & links!

To display the list of members with nested groups

18 June 2009


Members from Nested Group

To display the list of members, recursively expanded

In the below command, you can extract the group membership details, if you have a group that member of this group then this command will extract all the members including the nested groups(group with in the group)

So you will get all the members list form the group, members and members of members (nested groups)

syntex:

dsget group "Group DN" –members –expand

dsget user "User DN" –members –expand


Example:

dsget group "CN=sales,OU=test,DC=test,DC=com" –members –expand >c:\temp\members.txt

dsget user "CN=smith,OU=test,DC=test,DC=com" –members –expand >c:\temp\members.txt



If you don’t want the nested groups, only the members on the group or user then use the below command

syntex:

dsget group "Group DN" –members
dsget user "User DN" –members

Example:

dsget group "CN=sales,OU=test,DC=test,DC=com" –members >c:\temp\members.txt

dsget user "CN=smith,OU=test,DC=test,DC=com" –members >c:\temp\members.txt

Related Articles

how to find the ldap path

List active directory group members

find distinguished name

Share this . . .

1 comments:

Anonymous,  27 May 2014 at 04:54  

There is a mistake in your article. The dsget syntax for user does not have -members parameter. A -memberof switch is used instead. So the correct command is:

dsget user "User DN" -memberof -expand

Post a Comment

Copyright   © 2014 - www.Windowstricks.in - all rights reserved | Powered by Blogger | Blogger template The Beach by Ourblogtemplates.com

Back to TOP