Home > Exchange 2007, Powershell > Transport Rule Journal Selective Domain

Transport Rule Journal Selective Domain

If you want to journal a selective domain using a custom transport rule, this example shows how to use a custom transport rule to copy all emails from yahoo.com to a journal mailbox.

Open Exchange Shell and enter the following:

$Condition = Get-TransportRulePredicate FromAddressContains
$Condition.words = @(“yahoo.com”)
$Action = Get-TransportRuleAction Copyto
$Action.Addresses = @(get-mailbox “journal”)
New-TransportRule -Name “copy messages to journal mailbox” -Conditions @($Condition) -Actions @($Action)

This rule sends a copy to ie. CC’s the message to a journal mailbox. You can also opt to BCC by changing third line to:

$Action = Get-TransportRuleAction BlindCopyto

References:

How to Create a New Transport Rule
http://technet.microsoft.com/en-us/library/bb123927(EXCHG.80).aspx

Transport Rule Actions
http://technet.microsoft.com/en-us/library/aa998315(EXCHG.80).aspx

Transport Rule Predicates
http://technet.microsoft.com/en-us/library/aa998315(EXCHG.80).aspx

Advertisements
  1. RaiulBaztepo
    March 31, 2009 at 5:17 am

    Hello!
    Very Interesting post! Thank you for such interesting resource!
    PS: Sorry for my bad english, I’v just started to learn this language 😉
    See you!
    Your, Raiul Baztepo

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: