Creating dynamic groups in Exchange 2010

Creating dynamic groups in Exchange 2010

📧 Exchange 2010: Creating a Dynamic Distribution Group with PowerShell

Creating dynamic distribution groups in Exchange 2010 is a lifesaver because it automates member management. While you can also perform this operation using the Exchange Management Console (EMC), using the Exchange Management Shell (EMS) offers you many more filtering options.

Step 1: Opening the Exchange Management Shell

First, we open the Exchange Management Shell.

Step 2: Running the Command to Create a Dynamic Group

We will use the command below to create a dynamic group that will automatically include members based on specific criteria in Active Directory (in our example, Job Title: “Marka Müdürü” / Brand Manager).

Example Scenario: To create a group named “MarkaMud” that will automatically include all users who have a mailbox in Active Directory and whose Title is “Marka Müdürü” (Brand Manager).

Command:

PowerShell

New-DynamicDistributionGroup -Name "MarkaMud" -OrganizationalUnit "hurguc.local" -RecipientContainer "hurguc.local" -RecipientFilter {RecipientType -eq "UserMailbox" -and Title -eq "Marka Müdürü"}

🛠️ Explanation of Command Parameters:

  • -Name “MarkaMud”: The name of the dynamic group to be created.

  • -OrganizationalUnit “hurguc.local”: The Active Directory Organizational Unit (OU/Domain) where you are creating the group.

  • -RecipientContainer “hurguc.local”: The Active Directory container where the filtering will be performed (This is often the same as, or a broader scope than, the Organizational Unit).

  • -RecipientFilter {…}: The magical filter that determines who will be a member of the group:

    • RecipientType -eq "UserMailbox": Only include users who have a mailbox.

    • -and Title -eq "Marka Müdürü": AND include those whose Title is exactly “Marka Müdürü” (Brand Manager).


Thanks to this command, the group membership will automatically update the moment you change the “Title” field of the relevant users in Active Directory. Your dynamic list is now ready without human error!

Comments (0)

No comments yet. Be the first to comment!