Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'd like to exclude a single email address or recipient from an existing dynamic distribution group in Exchange 2010. The group is the generic "Everyone" group, and I'm interested in excluding the dedicated domain account used for our external mail journaling software (MailArchiva). I've seen references online to filtering on a custom attribute, but I'm seeking a solution that will allow something like:

Everyone = all Exchange mailboxes EXCEPT for 'Journal User'

It's a basic request, but the Exchange Management Console only seems to allow inclusions in its filters. Perhaps this is attainable via the Powershell.

share|improve this question

2 Answers 2

up vote 2 down vote accepted

You can exclude a specific user from a DD group with the Set-DynamicDistributionGroup commandlet. Specifically with the -RecipientFilter option.

Example: Set-DynamicDistributionGroup -Identity MadeUpName -RecipientFilter {((RecipientType -eq 'UserMailbox') -and -not(Name -like 'Journal User'))}

Note that this example is just with recipient type = userMailbox. You can get the current recipientFilter of your DD group and modify it however from powershell.

(get-DynamicDistributionGroup -Identity MadeUpName).RecipientFilter

share|improve this answer
    
Thank you I think this actually works! I wish the interface were a bit more intuitive, though. I could see organizations where Exchange PowerShell use could be a bit daunting... –  ewwhite Mar 12 '12 at 19:41

The only way I've seen to do this (maybe someone has a more efficient way) is with Transport Rules. I have a rule set up for the group applied to all messages sent to the e-mail address I want to exclude (or multiple addresses) where any recipient in To or CC is the distribution group address (be sure to include any aliases as well). The action to take is to delete without notification.

If an e-mail happened to be sent to the group and also had your exception address entered separately (To or CC), the message would still not be delivered. This probably won't matter in your case, but it's worth noting.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.