Active Directories Users and Computers is a basic tool of a Windows 2003 Active Directory environment. An often overlooked feature is the saved queries in ADUC. There is some information floating around but it's something I never really used much until recently. Also, getting a group membership to list is not intuitive and I had to get some help fro our friendly neighborhood resources to find out how to do that.
First, because I admin Exchange, we want to find all the users on a given Exchange Store.
- Open up Active Directory Users and Computers
- Under Saved Queries right click and select New -> Query
- Give it a name: Users on mailbox store X
- In Find select Exchange Recipients
- Uncheck everything except 'Users with Exchange mailbox'
- Select the Storage tab
- Check the 'Mailboxes in this mailbox store' radio button and browse to the stores you want.
- Click OK
So the next one is a little harder. You want to find all the members of a given distribution list. Why you ask? Well, perhaps all the users are on different stores and you want to move them or you just want the group membership.
- So under Saved Queries right click and select New -> Query
- Give it a name: members of x list
- Click 'Define queries'
- Under find select 'Custom Search'
- In the Custom Search tab select the 'Field' box and go to Users -> Member Of, Condition Is (Exactly), Value....
- So add the value
CN=\TeamDL,OU=Distribution lists,OU=someOU,DN=test,DN=ent - Save everything
Here's where it gets annoying. You need to have the Distinguished name of the group you want to search. So if your domain and OU structure looks like
test.ent
-someOU
--Distribution lists
----TeamDl
You would have a member list CN=\TeamDL,OU=Distribution lists,OU=someOU,DN=test,DN=ent
Run the query.

Post new comment