Solved

Does anyone know the PS command to add an individual user mailbox to a Dynamic Distribution Group?

Posted on 2015-02-17
5
102 Views
Last Modified: 2015-02-17
We have a number of Dynamic Distribution groups based on office location (e.g 'Everyone London') but occasionally need to add an individual from another office. In Exchange 2010 this does not seem possible through the EMC so does anyone know the correct PS command?
0
Comment
Question by:paulrixon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 24

Expert Comment

by:VB ITS
ID: 40613873
I don't think it's possible to add a user to a Dynamic Distribution Group. The group membership for DDG's are determined each time an email is sent to the group.

Second paragraph in this Technet article will confirm this: https://technet.microsoft.com/en-us/library/bb123722(v=exchg.141).aspx

You'll need to either set the attribute which determines the membership of the DDG on the user's account at the time you want them to be included in the group emails or modify the recipient filter of the DDG to include another attribute in AD you don't normally use (for example the Pager field in the Telephones tab).

You will still need to manually modify the attribute on the user's account to include them in emails sent to the DDG so either way manual intervention is required.
0
 

Author Comment

by:paulrixon
ID: 40613878
In 2003 you could modify the recipients filter to add individual users but this is greyed out in 2010. It says 'Use the Shell to modify the filter'.
0
 
LVL 24

Accepted Solution

by:
VB ITS earned 500 total points
ID: 40613924
Looks like you need to use the Set-DynamicDistributionGroup command. See this article for more information on this command: https://technet.microsoft.com/en-us/library/bb123796(v=exchg.141).aspx

As for including a single user in the DDG, something like this may work:
Set-DynamicDistributionGroup -Identity DDGName -RecipientFilter {((RecipientType -eq 'UserMailbox') -or (Name -like 'Other User'))}

Open in new window

I would personally create another DDG using the contents in the Filter tab of your existing DDG for testing. You can then look at incorporating the above code into your existing Recipient Filter.
0
 

Author Comment

by:paulrixon
ID: 40614091
Thank you very much. This worked a treat:

Set-DynamicDistributionGroup -Identity "DDGName" -RecipientFilter { RecipientType -eq 'UserMailbox' -and Office -eq 'Bergen' -or name -eq 'Username' }
0
 
LVL 24

Expert Comment

by:VB ITS
ID: 40614113
Sorry for originally misinterpreting what you wanted to do. Glad we got there in the end though :)
0

Featured Post

Are your AD admin tools letting you down?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

My attempt to use PowerShell and other great resources found online to simplify the deployment of Office 365 ProPlus client components to any workstation that needs it, regardless of existing Office components that may be needing attention.
There are times when we need to generate a report on the inbox rules, where users have set up forwarding externally in their mailbox. In this article, I will be sharing a script I wrote to generate the report in CSV format.
The basic steps you have just learned will be implemented in this video. The basic steps are shown to configure an Exchange DAG in a live working Exchange Server Environment and manage the same (Exchange Server 2010 Software is used in a Windows Ser…
There are cases when e.g. an IT administrator wants to have full access and view into selected mailboxes on Exchange server, directly from his own email account in Outlook or Outlook Web Access. This proves useful when for example administrator want…

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question