dsquery + dsget question


hi all,

we have ou in our domain holds bunch of universal distribution groups.  i'm trying use command combines dsquery dsget list of members of group , group names.  example:

dsquery group ou=test,dc=contoso,dc=com | dsget group -members

the above command lists of members each group doesn't list name of group well. ideas on how sneak name of groups in output well?

any appreciated, thanks.


it can done powershell ad cmdlets. acceptable?

$groups = get-adgroup -searchbase "ou=sales,dc=mydomain,dc=com" -filter * foreach ($group in $groups) {     $dn = $group.distinguishedname     "group: $dn"     $members = get-adgroupmember -identity $dn     foreach ($member in $members)     {         "    member: " + $member.distinguishedname     } }


richard mueller - mvp directory services



Windows Server  >  Directory Services



Comments

Popular posts from this blog

some help on Event 540

WMI Repository 4GB limit - Win 2003 Ent Question

Event ID 1302 (error 1307) DFS replication service encountered an error while writing to the debug log file