In the following example, the IncludedRecipients parameter specifies all
mailbox users in the organization. The Dynamic Distribution Group is created in the Users
Organizational Unit:
New-DynamicDistributionGroup -IncludedRecipients MailboxUsers -Name
???ExchMailboxUsers??? -OrganizationalUnit Users
Part I: PowerShell for Exchange Fundamentals
130
A custom filter can also be specified using the RecipientFilter parameter. The following filter
indicates all user mailboxes residing on server EX7B but excluding the system mailboxes. You must
exclude the system mailboxes especially if you are coexisting with Exchange Server 2000/2003:
New-DynamicDistributionGroup -Name ???EX7BMailboxUsers??? -OrganizationalUnit Users -
RecipientFilter {((RecipientType -eq ???UserMailbox??™ -and ServerName -eq ???EX7B??™) -and
-not(Name -like ???SystemMailbox{*??™))}
Unlike the Universal Distribution or Security Groups ( Get-DistributionGroupMembers ), it is not
possible to view the Dynamic Distribution Group members with a single cmdlet where a custom filter is
used. With the exception of precanned filters, the Exchange Management Console does not provide a
means yet of viewing a Dynamic Distribution Group ??™ s membership, unlike the preview button that
existed with the Query Based Distribution Group.
Pages:
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227