• Exchange 2010 Tip Of The Day – 51 To 75

    Here are the Exchange 2010 tips of the day from number 51 to 75.

    For the related articles in this series please see:

    Tips 1 - 25

    Tips 26 – 50

    Tips 76 - 101

    Tip of the day #51:

    Want to determine whether a server is running Exchange Server 2010 Standard Edition or Exchange Server 2010 Enterprise Edition? Type:

    Get-ExchangeServer <Server Name> | Format-Table Name, Edition

    If you want to view which edition all your Exchange servers are running, omit the <Server Name> parameter.

    Tip of the day #52:

    Want to create a new resource mailbox that can be used to book a meeting room? Type:

    New-Mailbox -Name <Conference Room Name> -UserPrincipalName <SMTP Address> -OrganizationalUnit <Organizational Unit> -Room

    This command creates a disabled Active Directory user who has a mailbox that accepts meeting requests from users.

    Tip of the day #53:

    Want to control the properties of e-mail messages sent to a specific domain? Use the RemoteDomain cmdlets. Create a new remote domain by using the New-RemoteDomain cmdlet. Type:

    New-RemoteDomain -Name "Contoso.com Configuration" -DomainName contoso.com

    Then modify the properties that you want for this remote domain by using the Set-RemoteDomain cmdlet:

    Set-RemoteDomain "Contoso.com Configuration" -AutoReplyEnabled $True -AutoForwardEnabled $True

    Tip of the day #54:

    You can control which features are available to Outlook Web Access users by using the Set-OwaVirtualDirectory cmdlet. Type:

    Set-OwaVirtualDirectory "OWA (Default Web Site)" -ContactsEnabled $True -ChangePasswordEnabled $True

    Tip of the day #55:

    Booleans are parameters that can be evaluated as either $True or $False. Booleans are typically used as a flag on an object that modifies the behavior of that object. In the Exchange Management Shell, you must supply a Boolean parameter with either a $True, $False, 1, or 0. No other values are accepted, including True or False. For example, both of the following commands set the enabled state of the ExampleAssignment management role assignment to $True:

    Set-ManagementRoleAssignment ExampleAssignment -Enabled $True
      Set-ManagementRoleAssignment ExampleAssignment -Enabled 1

    Tip of the day #56:

    Want an easy way to apply deleted item retention limits across multiple databases and servers? Try the following command to configure deleted item retention across all databases on a specified server:

    Get-MailboxDatabase -Server <Server Name> | Set-MailboxDatabase -DeletedItemRetention 45.00:00:00

    You can also apply the same deleted item retention limits or mailbox retention limits across all servers in your organization:

    Get-MailboxDatabase | Set-MailboxDatabase -DeletedItemRetention 45.00:00:00 -MailboxRetention 120.00:00:00

    Tip of the day #57:

    Want to know what permissions an Active Directory user account has on a specific mailbox? Use:

    Get-Mailbox <Mailbox to Check> | Get-MailboxPermission -User <Active Directory User>

    Tip of the day #58:

    Want to know which mailboxes a specific Active Directory user has permissions to? Type:

    $Mailboxes = Get-Mailbox -ResultSize Unlimited
      $Mailboxes | Get-MailboxPermission -User <Active Directory User> | Format-Table Identity, AccessRights, Deny

    Caution: This command enumerates all the mailboxes in your organization. If you have lots of mailboxes, you may want to target specific mailboxes.

    Tip of the day #59:

    Want to get a list of the backup status of all mailbox databases in your organization? Type:

    Get-MailboxDatabase -Status | Format-Table Name, Server, *Backup*

    How about just the mailbox databases on a specific server? Type:

    $Databases = Get-MailboxDatabase -Server <Server Name> -Status
      $Databases | Format-Table Name, *Backup*

    Tip of the day #60:

    To retrieve the current status of an Exchange server or database, use the Status parameter. For example:

    Get-ExchangeServer -Status | Format-List
      Get-MailboxDatabase -Server <Server Name> -Status | Format-List

    Tip of the day #61:

    Want to view the mounted status of all mailbox databases? Type:

    Get-MailboxDatabase -Status | Format-Table Name, Server, Mounted

    Tip of the day #62:

    What's the difference between server-side filtering and client-side filtering? Server-side filtering is used with the recipient and queue cmdlets, which support the Filter parameter, because these cmdlets can return large result sets. The server filters the results by using the criteria you specify and then sends you the filtered results. Client-side filtering can be used with any cmdlet. The entire result set is sent to the client computer, which then filters the data and provides a filtered result set. Client-side filtering uses the Where-Object cmdlet, which can be shortened to Where.

    Tip of the day #63:

    With Exchange Server 2010 Unified Messaging, you can redirect unauthenticated callers to certain telephone extensions to an operator instead of to the extension that was dialed. To list users for whom Unified Messaging transfers unauthenticated callers to the operator, instead of to the user, type:

    $Mailboxes = Get-UMMailbox
      $Mailboxes | Where-Object { $_.AllowUMCallsFromNonUsers -eq `
      [Microsoft.Exchange.Data.Directory.Recipient.AllowUMCallsFromNonUsersFlags] "None" }

    Tip of the day #64:

    You can use client-side filtering to return only the data that you want to see or work with. The following example retrieves all Active Directory user accounts in the Engineering department and puts the results in a table with two columns, Name and Department. By using the ResultSize parameter, the Get-User cmdlet limits the result set to 2,000 users.

    $Users = Get-User -ResultSize 2000
    $Users | Where { $_.Department -Eq "Engineering" } | Format-Table Name, Department

    Tip of the day #65:

    The special variable $_ represents the objects being passed from one cmdlet to another cmdlet in the pipeline. The $_ variable is automatically initiated by the Shell and is bound to the current pipeline object. You can access the properties of the object assigned to the $_ variable as you would any other object. The following example shows how you can view the Name property of each mailbox object that is passed through the pipeline:

    Get-Mailbox | ForEach { $_.Name }

    Tip of the day #66:

    You can import CSV files and treat them as objects by using the Import-Csv cmdlet. Each row in a CSV file becomes an element in an array, and each column becomes a property. You can assign the CSV file to a variable, or you can pipe its contents directly to another cmdlet. In the following example, there are three columns in the CSV file, Name, Alias, and EmailAddress, with several rows that the ForEach cmdlet will cycle through. The data in each row is used to create a new mail contact.

    $CSV = Import-Csv
      $CSV | ForEach { New-MailContact -Name $_.Name -Alias $_.Alias -ExternalEmailAddress $_.EmailAddress -OrganizationalUnit Users }

    Tip of the day #67:

    Want to customize your Exchange Management Shell profile? Run the following command to determine the location of your Microsoft.PowerShell_profile.ps1 file:

    $Profile

    You may have to create the PSConfiguration folder and Microsoft.PowerShell_profile.ps1 file. After you've done that, you can add your favorite functions and aliases, which will be loaded every time that the Exchange Management Shell is opened.

    Tip of the day #68:

    Want to see everything that occurs when you run a command? Include the Verbose parameter with the command. This parameter instructs the Exchange Management Shell to display detailed information about each action that the server takes to complete the command. This information can be useful in troubleshooting.

    Tip of the day #69:

    Any cmdlet that accepts a size value lets you specify whether the integer value is in kilobytes (KB), megabytes (MB), gigabytes (GB), or terabytes (TB). For example:

    Set-Mailbox "Kim Akers" -ProhibitSendQuota 200MB -UseDatabaseQuotaDefaults $False

    Tip of the day #70:

    Want to create a new role group for your administrators? Use the New-RoleGroup cmdlet. The New-RoleGroup cmdlet lets you add management roles and specify the members to add to the new role group. Those members will be granted the permissions provided by the management roles. Type:

    New-RoleGroup <role group name> -Roles <role 1>, <role 2>, <role 3...> -Members <member 1>, <member 2>, <member3...>

    Remember, role groups are used to grant permissions to groups of administrators or specialist end users who require special permissions. If you want to manage permissions for end users, use management role assignment policies.

    Tip of the day #71:

    Do you want to create a new management role assignment policy that's based on an existing policy, but you don't want to include all of the management roles? Use the Get-ManagementRoleAssignment cmdlet and pipe the results to the Where cmdlet. The Where cmdlet excludes any role assignments that contain the roles you specify. The remaining role assignments are piped to the New-ManagementRoleAssignment cmdlet. Type:

    New-RoleAssignmentPolicy <new role assignment policy name>
    Get-ManagementRoleAssignment -RoleAssignee <old role assignment policy name> | Where { ($_.Role -NE "<role name 1>") -And ($_.Role -NE "<role name 1>") } | New-ManagementRoleAssignment -Policy <new role assignment policy name>

    Then you can apply the new policy to a mailbox using the Set-Mailbox cmdlet:

    Set-Mailbox <mailbox name> -RoleAssignmentPolicy <new role assignment policy name>

    Tip of the day #72:

    Do you want to remove a management role from a role group, role assignment policy, USG or user but don't know the name o f the management role assignment? Just find the role assignment with the Get-ManagementRoleAssignment cmdlet and pipe the results to the Remove-ManagementRoleAssignment cmdlet. Type:

    Get-ManagementRoleAssignment -RoleAssignee <role assignee name> -Role <role name> | Remove-ManagementRoleAssignment

    Tip of the day #73:

    Exchange 2010 uses management role groups and management role assignment policies to manage permissions.  Role groups enable you to grant permissions to groups of administrators and specialist end users. These are people who manage your organization or perform special tasks, like mailbox searches for compliance reasons.  Role assignment policies enable you to grant permissions to your end users. These permissions include whether users can manage their own distribution groups, edit their own profile information, access voice mail, and more.

    Tip of the day #74:

    Exchange 2010 uses management role groups and management role assignment policies to manage permissions.
    Role groups enable you to grant permissions to groups of administrators and specialist end users. These are people who manage your organization or perform special tasks, like mailbox searches for compliance reasons.
    Role assignment policies enable you to grant permissions to your end users. These permissions include whether users can manage their own distribution groups, edit their own profile information, access voice mail, and more.

    Tip of the day #75:

    Exchange 2010 uses management role groups and management role assignment policies to manage permissions.
    Role groups enable you to grant permissions to groups of administrators and specialist end users. These are people who manage your organization or perform special tasks, like mailbox searches for compliance reasons.
    Role assignment policies enable you to grant permissions to your end users. These permissions include whether users can manage their own distribution groups, edit their own profile information, access voice mail, and more.

  • Exchange 2010 SP3 RU5 Released

    The Exchange team today announced the availability of Update Rollup 5 for Exchange Server 2010 Service Pack 3. RU5 is the latest rollup of customer fixes available for Exchange Server 2010. The release contains fixes for customer reported issues and previously released security bulletins.

    The astute reader will note that I did not post about the release of Exchange 2010 SP3 RU4 since that was a security release and contained only the security update in addition to SP3 RU3.

    Update:  17-3-2014 Please also see this article KB 2925273  Folder views are not updated when you arrange by categories in Outlook after you apply Exchange Server 2010 Service Pack 3 Update Rollup 3 or Update Rollup 4

    Update:   28-5-2014  The above issue contained in 2925273  is now corrected in Exchange 2010 SP3 RU6

    Exchange 2010 SP3 RU5 Released

     

    Exchange 2010 SP3 RU5 is not considered a security release as it contains no new previously unreleased security bulletin, but does contain all previous fixes. Exchange 2010 SP3 RU4 did include a security fix, which is present in RU5.

    This is build 14.03.0181.006 of Exchange 2010, and KB2917508 has the full details for the release.

     

     

    Updates Of Particular Note

    2913413 RPC Client Access service crashes with an exception in Exchange Server 2010

    2919513 Memory leak or memory corruption occurs in Exchange Server 2010

    2892257 Email items are lost when you move items between shared folders by using EWS delegate access

     

     

    Issues Resolved

    • 2887459 Public folder expiry time is set incorrectly in Exchange Server 2010 SP3
    • 2892257 Email items are lost when you move items between shared folders by using EWS delegate access
    • 2897935 "Cannot save the object '\FolderName'" error message when you try to replicate Exchange Server 2010 public folders
    • 2898908 EdgeTransport.exe crashes if the From field is empty in an email message
    • 2903831 Only a single character is allowed in the disclaimer content in ECP
    • 2904459 RPC Client Access service crashes if you add "Signed By" or "Send From" column in Outlook online mode
    • 2913413 RPC Client Access service crashes with an exception in Exchange Server 2010
    • 2913999 Meeting request body and instructions are lost in delegate's auto-forwarded meeting request
    • 2916836 EdgeTransport.exe crashes when a transport rule sends a rejection message to an empty address
    • 2919513 Memory leak or memory corruption occurs in Exchange Server 2010
    • 2924971 RPC Client Access service stops when you select an inactive search folder in Outlook 2007 in an Exchange Server 2010 SP3 environment
    • 2926057 EdgeTransport.exe crashes if seek operation failed in Exchange Server 2010
    • 2927856 Incorrect recurring meeting if disclaimer transport rule is enabled in Exchange Server 2010

     

    Important Notes

    Now, before we rush off to download and install this there are a couple of items to mention!

    • Test the update in your lab before installing in production.  If in doubt test…
    • If the Exchange server does not have Internet connectivity then this introduces significant delay in building the Native images for the .Net assemblies as the server is unable to get to http://crl.microsoft.com.  To resolve this issue, follow these steps:
      1. On the Tools menu in Windows Internet Explorer, click Internet Options, and then click the Advanced tab.
      2. In the Security section, click to clear the Check for publisher's certificate revocation check box, and then click OK.
      We recommend that you clear this security option in Internet Explorer only if the computer is in a tightly controlled environment. When setup is complete, click to select the Check for publisher’s certificate revocation check box again.
    • Update Internet facing CAS servers first
    • Backup any OWA customisations as they will be removed
    • Test (yes technically this is in here for a second time but it is important!)

     

    Cheers,

    Rhoderick

  • Exchange 2013 SP1 Released

    Exchange 2013 SP1 On Microsoft Download CenterExchange 2013 SP1 has now been released to the Microsoft Download Center

     

    The build number for Exchange Server 2013 SP1 is 15.00.0847.032

     

     

     

     

    Update 5-3-2014:  If you are using custom transport agents please see Third-party transport agents cannot be loaded correctly in Exchange Server 2013  The script you need to remediate the issue is linked from that KB, and is available directly from the download center.

    Update 14-4-2014:  As discussed in post “Patching Exchange? Don’t Overlook Outlook”, make sure to keep Outlook updated.  KB 2863911  Outlook 2013 profile might not update after mailbox is moved to Exchange 2013

    Update 14-4-2014:  Please see KB 2958434  if deleting Exchange 2013 databases.  Users cannot access mailboxes in OWA or EAS when mailbox database is removed

     

    As always please read the release notes!  Exchange 2013 SP1 contains schema changes and you will need to go through testing and validation to ensure a smooth rollout!

    Noted at the bottom of the Exchange Team Post the next Exchange 2013 update will be CU5.  Thus we could call this CU4, but Service Packs mark an important milestone for support lifecycle events so this do think of this as a Service Pack!

    You can download Exchange 2013 SP1 from here.

     

    Updates Of Particular Note

    Scroll down below for details on each of these features!

    • Windows Server 2012 R2 support for Exchange Server installation
    • Windows Server 2012 R2 Domain Function Level and Forest Function Level
    • Return Of the Mac Edge Transport
    • AD FS claims-based authentication with Outlook Web App and ECP
    • Hybrid deployments with multiple Active Directory forests
    • Database Availability Group without an Administrative Access Point

     

    Issues Resolved

    KB 2926248  contains the description for Exchange 2013 SP1. 

    • 2860242 HTML format is lost after saving as an MSG file in Exchange 2013
    • 2900076 Mailbox quota warning message uses an incorrect language in Exchange Server 2013
    • 2910199  "Reply all by IM" chat window displays seven recipients in Outlook Web App
    • 2913999  Meeting request body and instructions are lost in delegate's auto-forwarded meeting request
    • 2918655 Microsoft.Exchange.Servicehost.exe crashes after you enable FIPS
    • 2918951  Users cannot access public folders after you upgrade to Exchange Server 2013 Cumulative Update 3
    • 2925281 Outlook connectivity issue if SSLOffloading is "True" in Exchange 2013
    • 2925544 Empty ExternalURL value for ActiveSync virtual directory after build-to-build upgrade of Exchange Server 2013
    • 2927708  Resource mailboxes that are created by EAC will not be updated by policies in Exchange Server 2013
    • 2928748 Default from delegate's address in shared mailboxes in Exchange Server 2013
    • 2928803 Long server connection for Outlook after a database failover in Exchange Server 2013
    • 2930346 POP3 access does not work if the name of the resource mailbox differs from the user's name
    • 2930348 Manual redirection occurs in Outlook Web App if External URLs in each site are the same
    • 2930352 Outlook Web App cross-site silent redirection does not work in Exchange Server 2013

     

    Detailed Update Descriptions

     

    Windows Server 2012 R2 support

    Windows Server 2012 R2 is now a supported operating system in Exchange 2013 SP1. Exchange 2013 SP1 also supports installation in Active Directory environments running Windows Server 2012 R2. For more information, see Exchange 2013 System Requirements.

     

    Edge Transport

    Edge Transport servers minimize attack surface by handling all Internet-facing mail flow, which provides SMTP relay and smart host services for your Exchange organization, including connection filtering, attachment filtering and address rewriting. For more information, see Edge Transport Servers.

     

    OWA Junk Email Reporting

    OWA customers can report missed spam in the inbox (false negative) and misclassified as spam (false positive) messages to Microsoft for analysis by using its built-in junk email reporting options. Depending on the results of the analysis, we can then adjust the anti-spam filter rules for our Exchange Online Protection (EOP) service. For more information, see Junk Email Reporting in OWA.

     

    S/MIME for Message Signing and Encryption

    Microsoft Exchange Online and Exchange 2013 SP1 now support S/MIME-based message security. Secure/Multipurpose Internet Mail Extensions (S/MIME) allows people with Office 365 mailboxes to help protect sensitive information by sending signed and encrypted email within their organization. Administrators can enable S/MIME for Office 365 mailboxes by synchronizing user certificates between Office 365 and their on-premises server and then configuring Outlook Online to support S/MIME. For more information, see S/MIME for Message Signing and Encryption and the Get-SmimeConfigcmdlet reference.

     

    DLP Policy Tips available in the desktop and mobile version of Outlook Web App

    Data loss prevention (DLP) Policy Tips are informative notices that are displayed to senders in Outlook when they try sending sensitive information. In Exchange 2013 SP1, this functionality has been extended to both the desktop version of Outlook Web App and the mobile version (named OWA for Devices). You’ll see it in action if you have an existing DLP policy with Policy Tips turned on for Outlook. If your policy already includes Policy Tips for Outlook, you don't need to set up anything else. Go ahead and try it out!

    Not currently using Policy Tips? To get started, Create a DLP Policy From a Template, then add a policy tip by editing the policy and adding a Notify the sender with a Policy Tipaction.

     

    DLP Classification based on Document Fingerprints

    Deep content analysis is a cornerstone of DLP in Exchange. Document Fingerprintingexpands this capability to enable you to identify standard forms used in your organization, which may contain sensitive information. For example, you can create a fingerprint based off a blank employee information form, and then detect all employee information forms with sensitive content filled in.

     

    DLP sensitive information types for new regions

    SP1 provides an expanded set of standard DLP sensitive information types covering an increased set of regions, which makes it easier to start using the DLP features. SP1 adds region support for Poland, Finland and Taiwan. To learn more about the new DLP sensitive information types, see Sensitive Information Types Inventory.

     

    Using AD FS claims-based authentication with Outlook Web App and ECP

    Deploying and configuring Active Directory Federation Services (AD FS) using claims means multifactor authentication can be used with Exchange 2013 SP1 including supporting smartcard and certificate-based authentication in Outlook Web App. In a nutshell, to implement AD FS to support multifactor authentication:

    • Install and configure Windows Server 2012 R2 AD FS (this is the most current version of AD FS and contains additional support for multifactor authentication). To learn more about setting up AD FS, see Active Directory Federation Services (AD FS) Overview

    • Create relying party trusts and the required AD FS claims.

    • Publish Outlook Web App through Web Application Proxy (WAP) on Windows Server 2012 R2.

    • Configure Exchange 2013 to use AD FS authentication.

    • Configure the Outlook Web App virtual directory to use only AD FS authentication. All other methods of authentication should be disabled.

    • Restart Internet Information Services on each Client Access server to load the configuration.

    For details, see Using AD FS claims-based authentication with Outlook Web App and EAC

     

    SSL Offloading support

    SSL offloading is supported for all of the protocols and related services on Exchange 2013 Client Access servers. By enabling SSL offloading, you terminate the incoming SSL connections on a hardware load balancer instead of on the Client Access servers. Using SSL offloading moves the SSL workloads that are CPU and memory intensive from the Client Access server to a hardware load balancer.

    SSL offloading is supported with following protocols and services:

    • Outlook Web App

    • Exchange Admin Center (EAC)

    • Outlook Anywhere

    • Offline Address Book (OAB)

    • Exchange ActiveSync (EAS)

    • Exchange Web Services (EWS)

    • Autodiscover

    • Mailbox Replication Proxy Service (MRSProxy)

    • MAPI virtual directory for Outlook clients

    If you have multiple Client Access servers, each Client Access server in your organization must be configured identically. You need to perform the required steps for each protocol or service on every Client Access server in your on-premises organization. For details, see Configuring SSL Offloading in Exchange 2013

     

    Public Attachment Handling in Exchange Online

    Although there are both private (internal network) and public (external network) settings to control attachments using Outlook Web App mailbox policies, admins require more consistent and reliable attachment handling when a user signs in to Outlook Web App from a computer on a public network such as at a coffee shop or library. Go here for details, Public Attachment Handling in Exchange Online.

     

    Browser Support for AppCache

    Internet Explorer 10 and Windows Store apps using JavaScript support the Application Cache API (or AppCache), as defined in the HTML5 specification, which allows you to create offline web applications. AppCache enables webpages to cache (or save) resources locally, including images, script libraries, style sheets, and so on. In addition, AppCache allows URLs to be served from cached content using standard Uniform Resource Identifier (URI) notation. The following is a list of the browsers that support AppCache:

    • Internet Explorer 10 or later versions

    • Google Chrome 24 or later versions

    • Firefox 23 or later versions

    • Safari 6 or later (only on OS X/iOS) versions

     

    Exchange OAuth authentication protocol

    Information workers in Exchange on-premises organizations need to collaborate with information workers in Exchange Online organizations when they are connected via an Exchange hybrid deployment. New in Exchange 2013 SP1, this connection can now be enabled and enhanced by using the new Exchange OAuth authentication protocol. The new Exchange OAuth authentication process will replace the Exchange federation trust configuration process and currently enables the following Exchange features:

    • Exchange hybrid deployment features, such as shared free/busy calendar information, MailTips, and Message Tracking.

    • Exchange In-place eDiscovery

    For more information, see Configure OAuth Authentication Between Exchange and Exchange Online Organizations.

     

    Hybrid deployments with multiple Active Directory forests

    New in Exchange 2013 SP1, hybrid deployments are now supported in organizations with multiple Active Directory forests. For hybrid deployment features and considerations, multi-forest organizations are defined as organizations having Exchange servers deployed in multiple Active Directory forests. Organizations that utilize a resource forest for user accounts, but maintain all Exchange servers in a single forest, aren’t classified as multi-forest in hybrid deployment scenarios. These types of organizations should consider themselves a single forest organization when planning and configuring a hybrid deployment.

    For more information, see Hybrid Deployments with Multiple Active Directory Forests.

     

    Database Availability Group without an Administrative Access Point

    Windows Server 2012 R2 enables you to create a failover cluster without an administrative access point. Exchange 2013 SP1 introduces the ability to leverage this capability and create a database availability group (DAG) without a cluster administrative access point. Creating a DAG without an administrative access point reduces complexity and simplifies DAG management. In addition, it reduces the attack surface of a DAG by removing the cluster/DAG name from DNS, thereby making it unresolvable over the network.

    For more information, see High Availability and Site Resilience.

     

     

    Some Items For Consideration

    As with previous CUs, SP1 follows the new servicing paradigm that was previously discussed on the blog.  This package can be used to perform a new installation, or to upgrade an existing Exchange Server 2013 installation to SP1.  You do not need to install Cumulative Update 1 or 2 for Exchange Server 2013 RTM when you are installing SP1.

    After you install this Service pack, you cannot uninstall the Service Pack to revert to an earlier version of Exchange 2013. If you uninstall this Service pack, Exchange 2013 is removed from the server.

    Note that customised configuration files are overwritten on installation.  Make sure you have any changes fully documented!

    Once the Service Pack Installation has completed, restart the server.  The server should be restarted even if you are not prompted.

    Please enjoy the update responsibly!

    What do I mean by that?  Well, you need to ensure that you are fully informed about the caveats with the CU  and are aware of all of the changes that it will make within your environment.  Additionally you will need to test the CU your lab which is representative of your production environment.

     

    Cheers,

    Rhoderick

  • Exchange 2010 Tip Of The Day – 26 To 50

    Leading on where the previous post left off, here are the Exchange 2010 tips of the day from number 26 to 50.

    For the related articles in this series please see:

    Tips 1 – 25

    Tips 51 – 75

    Tips 76 - 101

    Tip of the day #26:

    Forget a property name? Not a problem because you can use wildcard characters to retrieve all properties that match the part of the name that you specify:

    Get-Mailbox | Format-Table Name,*SMTP*

    Tip of the day #27:

    Want to work with data contained in a CSV file? Use Import-CSV to assign the data to an object. For example, type:

    $MyCSV = Import-CSV TestFile.CSV

    You can then manipulate the data easily in the Exchange Management Shell. For example, if there is a column called Mailboxes in the CSV data, you can use the following commands to sort or group the data by the Mailboxes column:

    To sort: $MyCSV | Sort Mailboxes
    To group: $MyCSV | Group Mailboxes

    Tip of the day #28:

    This command spins through all your mailbox servers and reconnects all the uniquely identified but disconnected mailboxes in any one of the mailbox stores:

    $Servers = Get-ExchangeServer
      $Servers | `
      Where { $_.IsMailboxServer -Eq '$True' } `
      | ForEach { Get-MailboxStatistics -Server $_.Name `
      | Where { $_.DisconnectDate -NotLike '' } `
      | ForEach { Connect-Mailbox -Identity `
        $_.DisplayName -Database $_.DatabaseName} }

    Tip of the day #29:

    Tab completion reduces the number of keystrokes required to complete a cmdlet. Just press the TAB key to complete the cmdlet you are typing. Tab completion kicks in whenever there is a hyphen (-) in the input. For example:

    Get-Send<tab>

    should complete to Get-SendConnector. You can even use wildcards, such as:

    Get-U*P*<tab>

    Pressing the TAB key when you enter this command cycles through all cmdlets that match the expression, such as the Unified Messaging Mailbox policy cmdlets.

    Tip of the day #30:

    Tab completion reduces the number of keystrokes required to complete a cmdlet. Just press the TAB key to complete the cmdlet you are typing. Tab completion kicks in whenever there is a hyphen (-) in the input. For example:

    Get-Send<tab>

    should complete to Get-SendConnector. You can even use wildcards, such as:

    Get-U*P*<tab>

    Pressing the TAB key when you enter this command cycles through all cmdlets that match the expression, such as the Unified Messaging Mailbox policy cmdlets.

    Tip of the day #31:

    Tab completion reduces the number of keystrokes required to complete a cmdlet. Just press the TAB key to complete the cmdlet you are typing. Tab completion kicks in whenever there is a hyphen (-) in the input. For example:

    Get-Send<tab>

    should complete to Get-SendConnector. You can even use wildcards, such as:

    Get-U*P*<tab>

    Pressing the TAB key when you enter this command cycles through all cmdlets that match the expression, such as the Unified Messaging Mailbox policy cmdlets.

    Tip of the day #32:

    Tab completion reduces the number of keystrokes required to complete a cmdlet. Just press the TAB key to complete the cmdlet you are typing. Tab completion kicks in whenever there is a hyphen (-) in the input. For example:

    Get-Send<tab>

    should complete to Get-SendConnector. You can even use wildcards, such as:

    Get-U*P*<tab>

    Pressing the TAB key when you enter this command cycles through all cmdlets that match the expression, such as the Unified Messaging Mailbox policy cmdlets.

    Tip of the day #33:

    Want to create a group of test users in your lab? Use this command:

    1..100 | ForEach { Net User "User$_" MyPassword=01 /ADD /Domain; Enable-Mailbox "User$_" }

    Tip of the day #34:

    Like the Exchange Management Shell Tip of the Day? Try this:

    Get-Tip

    Tip of the day #35:

    Want to change the authentication settings on an Outlook Web Access virtual directory? Try the following command as an example. It changes authentication from forms-based authentication to Windows authentication:

    Set-OwaVirtualDirectory -Identity "OWA (Default Web Site)" -FormsAuthentication 0 -WindowsAuthentication 1

    Tip of the day #36:

    Want to set the properties on all or some Outlook Web Access virtual directories? Pipe the output of Get-OwaVirtualDirectory to the Set-OwaVirtualDirectory cmdlet. For example, the following command sets the Gzip level for all Outlook Web Access virtual directories:

    Get-OwaVirtualDirectory | Set-OwaVirtualDirectory -GzipLevel High

    Tip of the day #37:

    Want to remove an ActiveSync device from a user's device list? Type:

    Remove-ActiveSyncDevice

    This cmdlet can be helpful for troubleshooting devices that don't synchronize successfully with the server.

    Tip of the day #38:

    Want to clear all data from a mobile device? Use:

    Clear-ActiveSyncDevice

    Specify a time of day to clear the device, or let the task complete the next time that the device connects to the server
    .

    Tip of the day #39:

    Want to see a list of all devices that synchronize with a user's mailbox? Type:

    Get-ActiveSyncDeviceStatistics

    A variety of information is returned including device name, operating system, and last sync time.

    Tip of the day #40:

    Has one of your users asked you to recover their mobile device synchronization password? To return the user's password, type:

    Get-ActiveSyncDeviceStatistics -ShowRecoveryPassword

    Tip of the day #41:

    Want to move your database path to another location? Type:

    Move-DatabasePath -EdbFilePath DestFileName

    To change the file path setting without moving data, use this command together with the ConfigurationOnly parameter. This command is especially useful for disaster recovery. Caution: Misuse of this cmdlet will cause data loss.

    Tip of the day #42:

    Need an easy way to add a new primary SMTP address to a group of mailboxes? The following command creates a new e-mail address policy that assigns the @contoso.com domain to the primary SMTP address of all mailboxes with Contoso in the company field:

    New-EmailAddressPolicy -Name Contoso -RecipientFilter {Company -Eq "Contoso"} -EnabledPrimarySMTPAddressTemplate "@contoso.com"

    Tip of the day #43:

    Want to retrieve a group of objects that have similar identities? You can use wildcard characters with the Identity parameter to match multiple objects. Type:

    Get-Mailbox *John*
      Get-ReceiveConnector *toso.com
      Get-JournalRule *discovery*

    Tip of the day #44:

    Want to configure a group of objects that have similar identities? You can use wildcard characters with the Identity parameter when you use a Get cmdlet and pipe the output to a Set cmdlet. Type:

    $Mailboxes = Get-Mailbox *John*
    $Mailboxes | Set-Mailbox -ProhibitSendQuota 100MB -UseDatabaseQuotaDefaults $False

    This command matches all mailboxes with the name John in the mailbox's identity and sets the ProhibitSendQuota parameter to 100MB. It also sets the UseDatabaseQuotaDefaults parameter to $False so that the server uses the new quota you specified instead of the database default quota limits.

    Tip of the day #45:

    Forgot what the available parameters are on a cmdlet? Just use tab completion! Type:

    Set-Mailbox -<tab>

    When you type a hyphen (-) and then press the TAB key, you cycle through all the available parameters on the cmdlet. Want to narrow your search? Type part of the parameter's name and then press the TAB key. Type:

    Set-Mailbox -Prohibit<tab>

    Tip of the day #46:

    Want to add an alias to multiple distribution groups that have a similar name? Type:

    $Groups = Get-DistributionGroup *Exchange*
    $Groups | Add-DistributionGroupMember -Member kim

    This command adds the alias kim to all distribution groups that contain the word Exchange.

    Tip of the day #47:

    Want to record exactly what happens when you're using the Exchange Management Shell? Use the Start-Transcript cmdlet. Anything that you do after you run this cmdlet will be recorded to a text file that you specify. To stop recording your session, use the Stop-Transcript cmdlet.

    Notice that the Start-Transcript cmdlet overwrites the destination text file by default. If you want to append your session to an existing file, use the Append parameter:

    Start-Transcript c:\MySession.txt -Append

    Tip of the day #48:

    Do you have a user who has network access but maintains an external mail account outside your Exchange organization? With Exchange Server 2010, you can now create mail-enabled users that are regular Active Directory accounts, but also behave like mail-enabled contacts. By using the Enable-MailUser cmdlet, you can add e-mail contact attributes to any existing Active Directory user who doesn't already have a mailbox on an Exchange server. Users in your Exchange organization will then be able to send e-mail messages to that user's external mail account. Type:

    Enable-MailUser -Identity <Active Directory Alias> -ExternalEmailAddress <Destination SMTP Address>

    Tip of the day #49:

    Want to change the default prohibit send quota for a mailbox database? Type:

    Set-MailboxDatabase <Mailbox Database Name> -ProhibitSendQuota <New Quota Size> -UseDatabaseQuotaDefaults $False

    You can specify a bytes qualifier when you use the ProhibitSendQuota parameter. For example, if you want to set the prohibit send quota to 200 megabytes, type:

    Set-MailboxDatabase <Mailbox Database Name> ProhibitSendQuota 200MB -UseDatabaseQuotaDefaults $False

    You can also configure the IssueWarningQuota parameter and the ProhibitSendReceiveQuota parameter in the same way.

    Tip of the day #50:

    Want to know what version of Exchange Server each of your servers is running? Type:

    Get-ExchangeServer | Format-Table Name, *Version*

     

     

    Cheers,

    Rhoderick

  • Exchange 2010 Tip Of The Day – 1 To 25

    The Exchange Management Shell helps us discover the amazing capabilities of PowerShell.  One way it does this is by displaying a tip of the day so that we are introduced to concepts and topics that inevitably will come in handy one day!

    Since I had not see a complete list of the Exchange 2010 ones, I thought I’d jot them down.  Exchange 2007 Tips are listed on TechNet.

     

    Scroll down to the bottom for the PowerShell code used to retrieve this.  And yes, the first four tips really are duplicated, though since they are randomly displayed it goes un-noticed!  They remind me of a line from Red Dwarf *.

    For the related articles in this series please see:

    Tips 26 – 50

    Tips 51 – 75

    Tips 76 - 101

     

    Tip of the day #1:

    Did you know that the Identity parameter is a "positional parameter"? That means you can use:

    Get-Mailbox "user" instead of: Get-Mailbox -Identity "user"

    It's a neat usability shortcut!

    Tip of the day #2:

    Did you know that the Identity parameter is a "positional parameter"? That means you can use:

    Get-Mailbox "user" instead of: Get-Mailbox -Identity "user"

    It's a neat usability shortcut!

    Tip of the day #3:

    Did you know that the Identity parameter is a "positional parameter"? That means you can use:

    Get-Mailbox "user" instead of: Get-Mailbox -Identity "user"

    It's a neat usability shortcut!

    Tip of the day #4:

    Did you know that the Identity parameter is a "positional parameter"? That means you can use:

    Get-Mailbox "user" instead of: Get-Mailbox -Identity "user"

    It's a neat usability shortcut!

    Tip of the day #5:

    Tired of typing a long command every time that you want to do something? Alias it! Type:

    Set-Alias GetMre Get-ManagementRoleEntry

    For all the current aliases, type:

    Get-Alias

    Tip of the day #6:

    Want to see the members of a dynamic distribution group that has a custom filter? Just use the Get-Recipient cmdlet. Type:

    $DDG = Get-DynamicDistributionGroup "Contoso Marketing Managers"
      Get-Recipient -RecipientPreviewFilter $DDG.RecipientFilter

    Tip of the day #7:

    The Exchange Management Shell is a calculator too! Try it directly at a command prompt:

    1.2343+3123 or (23/435)*2

    Tip of the day #8:

    Command line SOS! Do you need help? Type:

    Help <cmdlet-name>  or  <cmdlet-name> -?

    You can choose what information to return when you view Help by using the Detailed, Full, and Examples switches:

    Help Get-Mailbox -Detailed

    Tip of the day #9:

    Want to look at Help for a cmdlet but don't want to read through pages and pages of text in the Shell window? Just use the Online switch with the Get-Help cmdlet. The Online switch tells the Shell to open the online version of the cmdlet's Help topic in your default browser. Type:

    Get-Help <cmdlet> -Online

    Tip of the day #10:

    The tilde character (~) should be familiar to Unix users. It represents the shortcut to your root directory. To see what it's evaluated to by default, type:

    Dir ~

    You can use it as a useful shortcut:

    Cp SomeFile "~\My Documents"

    Tip of the day #11:

    CTRL+C is the equivalent of the hard-break command in the Exchange Management Shell. If a command is taking too long to run or you want to cancel an operation quickly, press CTRL+C to stop execution.


    Tip of the day #12:

    Pushd and Popd work the same way in the Exchange Management Shell as they do in cmd.exe. Type:

    Pushd <location>

    Tip of the day #13:

    XML over everything! The Exchange Management Shell treats XML as a native type, so that you can do interesting things like:

    $Sample = [XML](Get-Content SomeXMLFile.xml)

    This command assigns $Sample to the actual XML object. To see it, type:

    $Sample

    To navigate, type:

    $Sample.Prop1.Prop2

    No need for text parsing when you want to load XML data!

    Tip of the day #14:

    Cmdlets that end in "Config" manage singleton configuration, either one per server or organization. For these tasks, you don't have to specify an identity because there is only one instance of the configuration. You may have to specify the Server parameter if the configuration is per server.

    Tip of the day #15:

    To get a list of all users on an Exchange 2010 server who aren't Unified Messaging-enabled, type:

    $Mailboxes = Get-Mailbox
      $Mailboxes | ForEach { If($_.UmEnabled -Eq $False){$_.Name}}

    Tip of the day #16:

    To get a list of all users on an Exchange 2010 server who are Unified Messaging-enabled, type:

    $Mailboxes = Get-Mailbox
      $Mailboxes = | ForEach { If($_.UmEnabled -Eq $True){$_.Name}}

    Tip of the day #17:

    To display the user's alias formatted in a table together with the user's Exchange 2010 server name and telephone extension, type:

    Get-Mailbox | Format-Table ServerName,@{e={$_.SamAccountName};Label="User Alias"},@{Expression="Extensions";Label="Telephone numbers"}

    Tip of the day #18:

    To display the list of UM IP gateway server names disabled for outbound calling and hunt groups associated with a UM IP gateway server, type:

    $Gateways = Get-UMIPGateway
      $Gateways | ForEach {If($_.OutCallsAllowed -Eq $False){ "Gateway Name = " +$_.Name;ForEach ($HuntGroup In $_.Huntgroups ){"Huntgroups " + $Huntgroup}}}

    Tip of the day #19:

    If you want to test all IP Block List providers, you just have to pipe the Get-IpBlockListProvider cmdlet to the Test-Ip BlockListProvider cmdlet:

    Get-IpBlockListProvider | Test-IpBlockListProvider -IpAddress 192.168.0.1

    Tip of the day #20:

    Before you remove an object by using the Remove verb, use the WhatIf parameter to verify the results are what you expect.

    Tip of the day #21:

    Sometimes it's useful to convert the output of a cmdlet to a string to interoperate with native cmdlets. For example, type:

    Get-Mailbox | Out-String | Findstr "Administrator"

    Tip of the day #22:

    Get all Win32 WMI information, such as Perfmon counters and local computer configurations. For example, type:

    Get-WMIObject Win32_PerfRawData_PerfOS_Memory

    Tip of the day #23:

    Who isn't tired of spam? You can configure real-time block list (RBL) providers with the Exchange Management Shell by running the following two commands:

    Set-IPBlockListProvidersConfig -Enabled $True -ExternalMailEnabled $True

    and then

    Add-IPBlockListProvider -Name <Name of RBL Provider> -LookupDomain <FQDN of RBL Provider> -AnyMatch $True

    Tip of the day #24:

    Access the event log from the Exchange Management Shell. To retrieve the whole event log, type:

    Get-EventLog Application | Format-List

    To retrieve all Exchange-related events, type:

    Get-EventLog Application | Where { $_.Source -Ilike "*Exchange*" }

    Tip of the day #25:

    One benefit of the Exchange Management Shell is that cmdlets can output objects to the console. You can then manipulate this output and organize it in interesting ways. For example, to get a quick view in tabular format, use Format-Table:

    Get-Mailbox | Format-Table Name,Database,RulesQuota

     

    Retrieving the Above Entries

    When the Exchange Management Shell shortcut is launched it does many things.  The properties of the shortcut show the following:

    C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -version 2.0 -noexit -command ". 'C:\Program Files\Microsoft\Exchange Server\V14\bin\RemoteExchange.ps1'; Connect-ExchangeServer -auto"

    RemoteExchange.ps1 calls another  script --– CommonConnectFunctions.ps1.  It is the latter script that creates the Get-Tip function which is called along with others to display the banner in the Exchange Management Shell.

    For more details on the Exchange Management Shell please review this post.

    Rather than go through and retrieve the tips one by one, PowerShell to the rescue!  You can either use option 1 and save this to a .ps1 script or option two and just run as a oneliner.

     

    Option 1 – Script File

    Save the below to a .ps1 file and execute it in the Exchange Management Shell.  Uses a While loop to iterate through all of the tips.

     

    # Initialise the counter with a value of 1.  
    $Int = 1

    # PowerShell While Loop.  Iterate to a count of 105 just to show that we have returned all tips
    While ($Int -le 105 )
    {  
        Get-Tip $Int
        Write-Host
         # Increment the counter
        $Int +=1
    }

     

    Option 2 – OneLiner

    If you would like to just cut and paste, without reading any comments in the above go ahead and run this:

    $Int = 1;While ($Int -le 105){Get-Tip $Int;  Write-Host; $Int+=1}

     

    The above PowerShell code will show all of the daily tips.  To save your scroll finger from total exhaustion, the tips are split into 4 separate posts.

     

    Cheers,

    Rhoderick

     

    * - A superlative suggestion, sir, with just two minor flaws.

    One: we don't have any defensive shields. And two: we don't have any defensive shields.

    Now I realise that, technically speaking, that's only one flaw; but I thought it was such a big one, it was worth mentioning twice.