TechShizz | All posts tagged 'Exchange 2010'

Client Access Array

 A client access array is a collection of load balanced Client Access servers. There can be one client access array per active directory site, and a single client access array cannot span multiple sites. Client access arrays are created using the New-ClientAccessArray cmdlet.

For example, to create a new client access array named clientarray.adatum.com in the Maffra site, use the following command:

 

New-ClientAccessArray –FQDN clientarray.adatum.com –Site Maffra –Name "clientarray .adatum.com"

 

Once the client access array is created, you assign the client access array to mailbox databases using the Set-MailboxDatabase cmdlet with the RpcClientAccess parameter. For example, to configure mailbox database ALPHA to use client access array clientarray.adatum. com, use the following command:

 

Set-MailboxDatabase ALPHA –RpcClientAccess clientarray.adatum.com

List of mailbox sizes

 

Get-MailboxStatistics -Database "DB1" | Select DisplayName, ItemCount, TotalItemSize | Sort-Object TotalItemSize -Descending | Export-CSV C:\MBSizes.csv


OR


Another we could use is:


get-mailboxstatistics | Sort-Object TotalItemSize -Descending | Select-Object DisplayName, @{label="TotalItemSize (MB)";expression={$_.TotalItemSize.Value.ToMB()}}, ItemCount | Export-CSV c:\filename.csv

Clone Edge Transport Server

In a production environment we would want to have the same configuration on each edge transport server. Rather than do this manually, we can use a special script to export the configuration of the first Edge transport server. The following is copied over when this is implemented:

  • Send and Receive connectors
  • Accepted Domains
  • Remote Domains
  • IP Allow/Block Lists
  • Anti Spam: Content filter/recipients filter/address rewrite entries and attachment entries.

 

To Clone

 

  1. Install the Edge transport role on the target server.
  2. Run: ./ExportEdgeConfig -cloneconfigdate:"C:\cloneconfigdata.xml"  on the source edge server. These scripts can be found at c:\Program Files\Microsoft\Exchange Server\V14\Scripts"
  3. Move the created XML file to the target edge server
  4. On the target server, create the reference XML by running  ./ImportEdgeConfig -cloneconfigdata:"c:\cloneconfigdata.xml" -isimport $false -cloneconfiganswer:"C:\cloneconfiganswer.xml"
  5. You will need to edit the XML to contain:
    1. Data and log file paths
    2. Source IP addresses for send connectors
    3. Network bindings for each connector.
  6. After editing the XML, run ./ImportEdgeConfig -cloneconfigdata:"c:\cloneconfigdata.xml" -isimport $true -cloneconfiganswer:"C:\cloneconfiganswer.xml" on the target server.

Configure POP and IMAP

To enable IMAP and POP3, the services need to be configured on the exchange server.

Enable IMAP and POP3 Service></p>

<p style=

They need to be started and set to start up automatically. 

 

Once this is done you cant go to the Server Configuration\Client Access node to configure. 

 

You can configure all the settings on these properties dialog boxes for each service

from the EMS by using the Set-POPSettings or Set-IMAPSettings cmdlets

 

You can test that these services are working correctly by using these EMS commands:

 

Test-POPConnectivity

 

Test-IMAPConnectivity


Managing Transport Rules

To get a full list of all transport rules predicates - Run this rule on the server with the Hub-Transport role.

 

Get-TransportRulePredicate | FT

 

These predicated can be a condition or an exception when used to identify matching criteria. 

 

 

Transport Rule Actions are applied when the messages match the conditions but no exceptions.

 

For a full list of actions type

 

Get-TransportRuleAction | FL

 

The output may be different depending on if this is run on the Hub Transport or the Edge Transport Server.

 

The following command creates the transport rule TransportRuleExample, which adds Kim Akers to the

recipients of any email messages sent to Mark Harrington except for messages that are sent by the external user DonalMace@Contoso.com:

 

New-TransportRule –Name TransportRuleExample –SentTo "Mark Harrington" –AddToRecipients

"Kim Akers" –ExceptIfFrom DonalMace@Contoso.com

 

 

Active Directory stores transport rules that are configured on Hub Transport servers so

that these transport rules are accessible to all Hub Transport servers in the organization

through Active Directory replication.

 

Transport rules that are configured on Edge Transport servers are stored in Active Directory Lightweight Directory Services (AD LDS) - Rules configured on one Edge Transport server do not automatically replicate to other Edge Transport servers in an Exchange organization.

Edge server transport rules apply to all types of message, cannot expand distribution group membership, cannot access Active Directory attributes, and cannot inspect or modify IRM-protected message content.


Coding a Transport Rule That Uses an Expression

Because regular expressions can appear to be complex and lead to lengthy EMS commands

being written to interpret such expressions, administrators often write code in the EMS to

implement such rules. This code is not complex programming but consists mainly of defining

variables that simplify the final statement of the rule.

A typical example detects that a number pattern is in the format of a U.S. Social Security

number.  The following code, entered into the EMS, creates a

transport

rule that prohibits the transmission of a U.S. Social Security number:

 

$Condition = Get-TransportRulePredicate SubjectMatches

$Condition.Patterns = @("\d\d\d-\d\d-\d\d\d\d")

$Action = Get-TransportRuleAction RejectMessage

$Action.RejectReason = "You are not permitted to transmit Social Security Numbers."

New-TransportRule -Name "Block Social Security Numbers" -Condition $Condition -Action

$Action

 

 

To modify a transport rule

 

Set-TransportRule