Unified Messaging - Pro Exchange 2013 SP1 PowerShell Administration: For Exchange On-Premises and Office 365 (2014)

Pro Exchange 2013 SP1 PowerShell Administration: For Exchange On-Premises and Office 365 (2014)

Chapter 8. Unified Messaging

With the rise of varied forms of electronic communications has come the need to converge these communication streams into integrated forms known as unified communications. Presently, this involves the integration of primarily real-time services, such as instant messaging, telephony (voice over IP, or VOIP), and video conferencing. Unified communications allows messages to be sent through one medium and received on a different medium. Though VOIP was well adopted by enterprises at the time of its inception, there remained a clear desire to extend the functionality to other forms of communication—for example, being able to leave voice-mail messages in mailboxes instead of on proprietary voice-mail systems.

Unified messaging, according to the International Engineering Consortium, is the integration of different electronic messaging and communications media technologies into a single interface that’s accessible from a variety of devices and that’s applicable to email, SMS, fax, voice mail, and video messaging. This description of the term embraces the concept’s multi-disciplinary aspects and its complexity, reflecting the extensive technical knowledge required of the involved components.

In what seems decades ago, vendors like Cisco, Avaya, and Mitel offered products to integrate their telephony solutions with messaging—for example, through dedicated voice-mail systems. Starting with Exchange Server 2007, Microsoft attempted to bridge the gap between PBX solutions and messaging by natively offering integration with supported IP-PBX systems. Most prominent, its unified messaging feature provided a universal inbox for email, inbound faxes, and voice-mail messages, as well as voice-controlled mailbox access using Outlook Voice Access (OVA).

In Exchange 2010, the Unified Messaging (UM) server role was enhanced with an MP3 codec, which allowed Exchange to encode or decode audio streams. Another unified messaging feature that was introduced with Exchange 2010 was voice-mail preview, at that time an innovative function that attempted to insert a transcript of the recorded voice-mail message into the body of the accompanying email message. With Exchange 2010, inbound FAX integration was dropped, as Microsoft deemed it not popular. Customers looking to integrate FAX-over-IP solutions as part of their unified messaging strategy, therefore, needed to incorporate third-party solutions.

Exchange 2013 provides solid, cost-effective UC features that can replace third-party solutions such as voice-mail services. In conjunction with supported IP telephony solutions such as Lync Server, Exchange can offer a rich end-user experience that tightly integrates voice communications with an email solution via a single, unified user interface. This chapter explores these features, with the next section presenting an overview and the following sections explaining them in more detail.

Features of Unified Messaging

The unified messaging services provided by Exchange 2013 include the following features:

· Voice mail, a complete built-in voice-mail system, tightly integrated with the user’s mailbox, that offers access to the voice mails on every device and at any time.

· Voice-mail preview, a speech-to-text transcription of recorded voice-mail messages, whereby the text is added to the message body. This voice-mail preview is created only when there are enough resources available on the UM server, a UM language pack is installed for the language used, and the language pack supports voice-mail preview. (There’s more information on language packs later.)

· Outlook voice access, for using a normal phone to access the Exchange mailbox (email, calendar). You can, for example, have your messages read by the system or you can change meeting requests when you are running late.

· Play on phone, such that after a voice mail is delivered, it can generate a phone call to the dialed number and play the message.

· Call answering, for answering incoming calls and playing or recording messages. Users can create rules to control the answering of phone calls, with methods that are similar to those for setting up inbox rules; for example, here are some possibilities:

· Leaving a voice-mail message

· Transferring the call to another recipient

· Transferring the call to another recipient’s voice mail

· Transferring the call to an external phone number

· Message waiting indicator, a popular notification option whereby a signal is shown when a new voice-mail message has arrived.

· Missed call and voice-mail notifications using SMS, for notifying users on configured cell phones of missed calls or new voice-mail messages.

· Protected voice mail, allowing users to utilize Rights Management Services (AD RMS) to protect their voice-mail messages or disallowing the forwarding of voice-mail messages.

· Group addressing, allowing users to send email and voice messages to a group that is defined in their Contacts folder.

· Caller ID, as enhanced in Exchange Server 2013, tries to resolve the caller’s telephone number and display it in a voice-mail notification message. It consults Active Directory and the user’s Personal Contacts folder.

When you combine Exchange 2013’s unified messaging with a Microsoft Lync Server 2013 environment, especially when the Lync Server 2013 is configured for Enterprise Voice, you can build a consolidated, powerful voice-mail system.

Image Note The examples in this chapter assume you have a fully functional IP telephony infrastructure set up, like Lync Server 2013 with Enterprise Voice enabled.

The Role of Unified Messaging

In Exchange Server 2007 and Exchange Server 2010, the unified messaging functionality was offered through the UM server role. This was a separate server role that could be installed on a dedicated server. The architectural changes in Exchange 2013 reduced the UM server role to those of the Client Access servers and Mailbox servers, and this had consequences for the UM server role. Whereas previously the unified messaging function was a separate Exchange server role, in Exchange 2013 it is separated into two functions:

· Unified messaging call router runs on the Exchange 2013 Client Access server and is responsible for receiving initial requests from Session Initiation Protocol (SIP) messages from the IP-PBX and redirecting those requests to the appropriate Mailbox server where the designated mailbox is active.

· The Unified messaging service runs on Exchange 2013 Mailbox servers, and is responsible for recording the messages and sending them to the corresponding user’s mailbox through the Transport service.

SIP is the protocol to create or manage sessions; by default, it uses port 5060 for unsecured SIP traffic, whereas secure SIP uses port 5061 (see Figure 8-1). Media, or the audio stream, is transported directly between the IP-PBX or VoIP gateway and the Mailbox server using the Real-time Transport Protocol (RTP) or secure Real-time Transport Protocol (SRTP) protocol.


Figure 8-1. Exchange 2013 unified messaging traffic

Image Note The SIP is the de facto signaling protocol for controlling audio or video sessions over IP networks. Discussing SIP would produce a book in itself. If you’re looking for more informaiton on SIP, you’ll find information from the Internet Engineering Task Force in RFC 3261, available at https://www.ietf.org/rfc/rfc3261.txt.

The UM call router running on Exchange 2013 CAS servers will, by default, listen for unsecured (TCP/5060) and secured (TLS/5061) SIP traffic. If you want to change this, you can adjust the UM startup mode by using the Set-UMCallRouterSettings cmdlet with theUMStartupMode parameter. For example, to configure all Client Access servers to use only unsecured mode, you use:

Get-ClientAccessServer | Set-UMCallRouterSettings -UMStartupMode TCP

The UM service running on the Exchange 2013 Mailbox servers will listen for unsecured (TCP/5062) and secured (TLS/5063) SIP traffic as well, but on different ports. To adjust this, you can change the UM startup mode by using the Set-UMService cmdlet. For example, to configure all Mailbox servers to use only unsecured mode, you use:

Get-MailboxServer | Set-UMService -UMStartupMode TCP

Note that you can change behavior for a single server by specifying its identity; for example,

Set-UMCallRouterSettings -Identity EX2010UM1 -UMStartupMode TLS

Or, for Mailbox servers, you use the following:

Set-UMService -Identity EX2010UM2 -UMStartupMode TLS

To restore UM services to listen to both ports, you specify Dual as the startup mode, as follows:

Get-ClientAccessServer | Set-UMCallRouterSettings -UMStartupMode Dual
Get-MailboxServer | Set-UMService -UMStartupMode Dual

Image Note Using TLS or TLS in dual mode requires configuring a valid TLS certificate. There’s more on configuring TLS certificates later in this chapter.

Objects of Unified Messaging

To integrating the Exchange unified messaging function into your existing telephony infrastructure, you define several components that make up your IP telephony infrastructure and set your connection options. Successful implementation of unified messaging depends on proper definition of these components: UM dial plans, UM IP gateways, and UM hunt groups. Let’s look at each of these objects and see how to configure them.

Image Note To perform management tasks on UM-related objects, you need to be assigned the UM Management or Organization Management role.

UM Dial Plans

An important piece of information in telephony is a dial plan, or in this case, a UM dial plan. This dial plan defines the groups of telephone extension numbers, similar to subnets in IPv4 addressing. Using the same analogy, the number of digits in an UM dial plan can be viewed as the opposite of a subnet mask. Whereas the subnet mask defines the number of bits used to separate subnet information from host address information, the number of digits in a UM dial plan defines the number of digits used in digit sequence as part of a group of extensions. A UM dial plan contains a single range of numbers; it cannot contain multiple ranges.

For Exchange UM to answer incoming calls, you need to create at least one UM dial plan. Creating a dial plan requires the following pieces of information:

· Name. This name is used to identify the dial plan and is also used to create a similarly named default policy that’s related to the dial plan.

· Number. The number of digits used to specify the extension in NumberOfDigits.

· UriType. Used to define how to link phone numbers to mailboxes; depends on the IP PBX used in your organization. You can specify one of the following types:

· TeleExtn for IP PBXs supporting the telephone extension URI; for example, Tel:1234 or 1234@

· SIPname for IP PBXs supporting the email address-like SIP URIs; for example, sip:<user>@<domain>. To integrate Exchange 2013 with Lync, you use UriType SIPname.

· E.164 for IP PBXs supporting E.164 routing; for example, Tel:+31101234567890.

· VoIPSecurity to specify if you want Exchange to communicate with IP-PBXs and other Exchange servers in unsecured, SIP secured, or secured mode.

Image Note In VoIP unsecured security mode, all traffic is unencrypted. In secured mode, all traffic is encrypted, including signaling (SIP) and media (RTP). In SIP secured mode, only SIP signaling traffic is encrypted; RTP media remains unencrypted.

· Country code. Optionally, you specify CountryOrRegionCode to configure the associated language of the pre-recorded prompts, automatic speech recognition (ASR) of spoken audio, and pronunciation and rules for text-to-speech synthesis and the related name recognition.

· Telephone numbers. You specify the telephone numbers to be used for Outlook Voice Access. On UM dial plans, greetings and informational announcements are played when calling an Outlook Voice Access number.

Image Caution Before a configured CountryOrRegionCode is used by Exchange, the language pack supporting the specified language should be present on the Exchange Mailbox server.

To create a UM dial plan, you can use the Exchange Admin Center, via Unified Messaging image UM dial plans section (see Figure 8-2). Click the + sign to add a new dial plan, and enter the required information, such as the name of the dial plan and the extension length.


Figure 8-2. UM dial plan choices in Exchange Admin Center

Some UM dial plan configuration options are only configurable after you’ve created a new UM dial plan, done by editing its properties. You select the just created UM dial plan, and choose the Edit option. You will notice that there are a lot more options available now than when you were creating the UM dial plan. To access the UM dial plan settings, you click the Configure button. You can now configure all available UM dial plan options (see Figure 8-3).


Figure 8-3. Configuring the UM dial plan settings using Exchange Admin Center

Image Note When testing, you may need to configure the UM dial plan’s dialing rules and dialing authorization to allow unrestricted calling. Following the examples used in this chapter, you use the following to configure the UM dial plan to allow unrestricted calls:

Set-UMDialPlan 'Contoso Dial Plan' -ConfiguredInCountryOrRegionGroups 'Anywhere,*,*,*'

-AllowedInCountryOrRegionGroups "Anywhere". You may also need to set unrestricted authorization on UM mailbox policies—for example, Set-UMMailboxPolicy -Identity 'Contoso Dial Plan Default Policy' -AllowedInCountryOrRegionGroups 'Anywhere'. Be sure to remove or reconfigure these settings before going live.

The cmdlet to create a dial plan is New-UMDialPlan. For example, to create a dial plan for Lync, using three digits, unsecured mode, using US (code 1) as the associated language, and using 900 as the subscriber number for Outlook Voice Access, you employ something like this:

New-UMDialPlan -Name 'Contoso Dial Plan' -Uritype SIPName -NumberofDigits 3 -VoIPSecurity Secured -CountryOrRegionCode 1 -AccessTelephoneNumbers 900

Next, you associate a unified messaging IP gateway and Mailbox server with the UM dial plan.

Image Note Should your infrastructure require use of ports different from 5060 for unsecured SIP and 5061 for secured SIP, you can use Set-UMCallRouterSettings to reconfigure those ports using the SipTcpListeningPort and SipTlsListeningPort parameters—for example,

Set-UMCallRouterSettings -SipTcpListeningPort 5560 -SipTlsListeningPort 5561.

Should you need to change those required ports for any down-level Exchange 2010 UM server, you use Set-UMService with the same parameters—for example,

Set-UMService -Identity EX2010UM1 - SipTcpListeningPort 5560 - SipTlsListeningPort 5561.

When using Lync or OCS 2007 R2 as IP-PBX, you need to associate the CAS servers (UM call routers) with a UM dial plan using Set-UMCallRouterSettings; for example,

Set-UMCallRouterSettings -Server ams-exch01.contoso.com -DialPlans 'Contoso Dial Plan'

If you want to reconfigure the UM call router service on all CAS servers at once so that they use only the Contoso dial plan, you enter:

Get-ClientAccessServer | Set-UMCallRouterSettings -DialPlans 'Contoso Dial Plan'

DialPlans is a multi-valued attribute. If you want to add ‘Contoso Dial Plan’ to the current set of configured dial plans, you use:

Get-ClientAccessServer | Set-UMCallRouterSettings -DialPlans @{Add='Contoso Dial Plan'}

Should you need to remove ‘Contoso Dial Plan’ from all CAS servers, you can use:

Get-ClientAccessServer | Set-UMCallRouterSettings -DialPlans @{Remove='Contoso Dial Plan'}

And should you need to remove a CAS server from servicing any UM dial plan, you set DialPlans to $null; for example,

Set-UMCallRouterSettings -Server lon-exch01.contoso.com -DialPlans $null

If you want to configure Outlook Voice Access, you can do so by editing the related UM dial plan from the Exchange Admin Center, assigning it at least one E.164 telephone number, also known as the subscriber access number, on which Outlook Voice Access should be reachable.

To configure an Outlook voice access number for an UM dial plan, you can also use Set-UMDialPlan providing the E.164 numbers to be used, with the AccessTelephoneNumbers parameter; for example,

Set-UMDialPlan -Identity 'Contoso Dial Plan' -AccessTelephoneNumbers @('+3112345601')

When integrating Exchange UM with OCS or Lync Server, you can use a tool OcsUmUtil.exe, which performs the following tasks:

· Creates contact objects for each UM auto attendant.

· Creates contact objects for each subscriber access number.

· Verifies the Lync Enterprise voice location profile information against the UM dial plans.

The OcsUmUtil.exe tool is by default located in the %CommonProgramFiles%\Microsoft Lync Server 2013\Support folder on a Lync 2013 server. When run without parameters, the tool starts in GUI mode. You can also provide the forest to scan for Exchange UM objects and the SIP domain for which to configure contact objects using the /forest and /domain parameters, after which the tool will create the required objects (see Figure 8-4). If you have relocated the UM auto attendant objects from their default location, which is the RTC Special Accounts OU in the root of your Active Directory tree, you may need to specify /ou as well together with correct location.


Figure 8-4. Creating Exchange UM contact objects using OcsUmUtil.exe

UM IP Gateway

To configure where Exchange can receive and send calls to, you need to configure an UM IP gateway, which represents your IP telephony endpoint that could be an IP-PBX or voice gateway. New in Exchange 2013 is that unified messaging now fully supports IPv6. Thus, unlike earlier versions of unified messaging in Exchange, it is no longer necessary to have IPv4 next to IPv6 so that unified messaging will work on IPv6 networks.

Image Caution If you are running OCS or Lync Server, you can skip manually creating the UM IP gateway and instead run the script ExchUcUtil.ps1, which is located in the $exscripts folder. Run this script from a Mailbox server. This script will create an UM IP gateway for each existing Lync pool and it will give Lync groups the necessary permissions on Exchange UM objects in Active Directory. If you have any existing UM IP gateway definitions, disable outgoing calls on those UM IP gateways by using Set-UMIPGateway -Identity <Name> -OutCallsAllowed $false.

To create an UM IP gateway definition, you can use the Exchange Admin Center, via Unified Messaging image UM IP Gateways. Click the + sign to add a new dial plan (see Figure 8-5). Then specify a name for the IP gateway, give its FQDN or address, and select a dial plan to associate with this UM IP gateway.


Figure 8-5. Creating a UM IP gateway using Exchange Admin Center

Image Note You can have up to 200 UM IP gateways configured per dial plan.

To create an UM IP gateway object using Exchange Management Shell, employ the New-UMIPGateway cmdlet, specifying a name, give its FQDN or address, and select the UM dial plan to associate it with this UM IP gateway; for example,

New-UMIPGateway -Name 'CCM01' -Address -UMDialPlan 'Contoso Dial Plan'

The output of this cmdlet is shown in Figure 8-6.


Figure 8-6. Creating a UM IP gateway definition using New-UMIPGateway

If you want to specify an IPv6 address, you need to use the IPAddressFamily parameter as well, as by default it will be set to use IPv4Only, which means IPv4 is used. To enable use of the IPv6 address, set IPAddressFamily to IPv6Only. Alternatively, you can configureIPAddressFamily as Any, in which case Exchange will try connecting by using IPv6 and only fall back to IPv4 if it can’t connect using IPv6.

So, to reconfigure the previously created UM IP gateway to use a FQDN of lync.contoso.com, and to use protocols IPv6 with fallback to IPv4, you use:

Set-UMIPGateway -Identity 'CCM01' -Address 'lync.contoso.com' -IPAddressFamily Any

Image Note If your IP-PBX is listening on a port other than 5060, you can use Set-UMIPGateway with the Port parameter to use a different port—for example, Set-UMIPGateway -Identity 'CCM01' Port 5061.

When required, you can disable and (re)enable a UM IP gateway object. When disabled, calls will not be routed to the host or address configured with the disabled UM IP gateway definition. To disable a UM IP gateway, you use Disable-UMIPGateway; for example,

Disable-UMIPGateway -Identity 'CCM01'

Note that this will gracefully disable the UM IP gateway by finishing the current sessions but disallow new calls. When required, you can forcefully terminate current calls as well by setting the Immediate parameter to $true; for example,

Disable-UMIPGateway -Identity 'CCM01' -Immediate $true

To enable the UM IP gateway again, you use Enable-UMIPGateway, as follows:

Enable-UMIPGateway -Identity 'CCM01'

UM Hunt Groups

A hunt group is a single telephone number that can be associated with sets of extensions to distribute incoming calls. For example, a support desk can have 10 extension numbers all of which are associated with a single hunt group telephone number.

In Exchange UM, an extension number associated with a hunt group is also called a pilot number. This number is contained in the SIP INVITE message from the IP-PBX, allowing an Exchange server to match it against the hunt group to which it belongs. If there is a match, the call is answered.

A UM hunt group definition consists of the following elements:

· Name of the Hunt Group.

· UMDialPlan to specify the name of the UM dial plan to associate with the UM hunt group.

· Optionally, PilotIdentifier to specify one or more pilot numbers attached to the hunt group in use.

· UMIPGateway to specify the name of the UM IP gateway object to associate with the hunt group.

So, to create a new hunt group named ContosoIT, using a pilot identifier of 123, and associating it with UM dial plan ‘Contoso Dial Plan’ and UM IP Gateway ‘LyncHQ,’ you use:

New-UMHuntGroup -Name 'ContosoIT' -PilotIdentifier 123
-UMDialPlan 'Contoso Dial Plan' -UMIPGateway 'LyncHQ'

The output of this cmdlet is shown in Figure 8-7.


Figure 8-7. Creating a UM hunt group using New-UMHuntGroup

Image Note Previous versions of Exchange unified messaging required hunt groups to be associated with a pilot number. This is optional in Exchange 2013. When not specified, calls can be routed from a UM call routing server to any Exchange 2013 Mailbox server.

UM Mailbox Policies

Much like regular mailbox policies, UM mailbox policies determine the UM-related settings that apply to UM-enabled users, done by creating UM mailbox policy objects and assigning them to UM-enabled users. UM mailbox policies allow organizations to configure the following settings:

· UM features

· PIN policies

· UM message-customization options

· Call authorization options

· Voice-mail security options

To create a UM mailbox policy from the Exchange Admin Center, navigate to unified messaging image UM dial plans. Select a UM dial plan and click the Edit icon. You will notice that there are now additional settings available compared to when you were creating a UM dial plan. Notice also that there is a default UM mailbox policies section, which shows the UM mailbox policy that was created when the UM dial plan was established. This default UM mailbox policy is named <UM Dial Plan> Default Policy, as shown in Figure 8-8.


Figure 8-8. Configuring UM dial plan options using Exchange Admin Center

Now you can edit the properties of the existing UM mailbox policy or click the New icon to create a new UM mailbox policy and have it associated with the active UM dial plan. To configure some of the most common UM mailbox policy settings, you specify one or more of the following parameters when using New-UMMailboxPolicy, or use them together with the Set-UMMailboxPolicy cmdlet:

· AllowAutomaticSpeechRecognition specifies if users can use automatic speech recognition (ASR).

· AllowCallAnsweringRules specifies if users are allowed to configure call answering rules. (There’s more on call answering rules later in this chapter.)

· AllowCommonPatterns specifies if users are allowed obvious PIN codes, such as 11111 or 12345.

· AllowFax specifies if the user is allowed to receive inbound faxes. Make sure to configure FaxServerURI as well.

· AllowMessageWaitingIndicator specifies if the user is allowed to receive message waiting indicator (MWI) notifications when a new voice mail is received.

· AllowMissedCallsNotifications specifies if the user will receive missed call notifications.

· AllowPinlessVoicemailAccess specifies if the user can access voice mail without being required to enter a PIN code. Note that a PIN is still required to access the user’s regular mailbox—for example, email and calendar information.

· AllowPlayOnPhone specifies if the user can play back voice-mail messages on her phone. (There’s more on play on phone later in this chapter.)

· AllowSMSNotification specifies if the user is allowed to receive text messages. Note that in order to receive these messages, the UMSMSNotification option needs to be configured as VoiceMail or VoiceMailAndMissedCalls, using Set-UMMailbox.

· AllowSubscriberAccess specifies if the user is allowed subscriber access to his mailbox to receive voice-mail messages, for instance.

· AllowVoiceMailPreview specifies if the user is enabled to receive voice-mail previews for call-answer-rule answered messages, or voice-mail messages the user sent to other users.

· AllowVoiceResponseToOtherMessageTypes specifies if users can attach voice-mail messages to email messages or calendar items.

· FaxMessageText specifies the text to include in the body of fax messages.

· FaxServerURI specifies the SIP URI of the fax solution.

· LogonFailuresBeforePINReset specifies the number of failed PIN logins before the PIN is automatically reset. To disable this behavior, set LogonFailuresBeforePINReset to Unlimited.

· MaxGreetingDuration limits the time of the greeting, ranging from 1 to 10 minutes. Default is 5 minutes.

· MaxLogonAttempts specifies the maximum number of failed logons after which to lock an UM-enabled mailbox. Value can range from 1 to 999. Default value is 15.

· MinPINLength specifies the minimum required PIN length, ranging from 4 to 24 digits. Default value is 6.

· PINHistoryCount specifies the number of previous PINs to remember, disallowing their usage. This setting can range from 1 to 20. Default is set to 5.

· PINLifetime specifies the number of days until a new PIN is required, ranging from 1 to 999. The default value is 60. Set this value to Unlimited to have a non-expiring PIN.

· ResetPINText specifies the text to include in PIN reset email messages.

· UMDialPlan specifies the name of the associated UM dial plan.

· UMEnabledText specifies the text to include in the email message sent when a user gets UM-enabled.

· VoiceMailText specifies the text to include in voice-mail notification email messages.

So, to reconfigure an existing UM mailbox policy named ‘Contoso Dial Plan Default Policy,’ you use:

Set-UMMailboxPolicy -Identity 'Contoso Dial Plan Default Policy'
-LogonFailuresBeforePINReset Unlimited -MinPINLength 4 -PINLifetime 30

Image Note The “Message Waiting” indicator feature leverages Exchange’s Search folder functionality. A separate Voice Mail Search folder is created for UM-enabled users, to which the mailbox assistant subscribes and sends SIP NOTIFY messages when new messages are found. “Message Waiting” indicator messages are not available to users with a mailbox hosted on Exchange 2010 or Exchange 2007.

Image Caution When a new voice mail has been detected by the mailbox assistant, it triggers the UM server to send a SIP NOTIFY message to the IP-PBX, which should notify the user or endpoint. This kind of unsolicited notification needs to be supported by your IP-PBX or the user will not receive MWI notifications.

UM Auto Attendant

Exchange unified messaging allows you to create UM auto attendants. These are optional configuration objects per UM dial plan. They allow callers to receive corporate or information messages, locate users, or automatically answer and route incoming calls through a voice-menu system. Some of these settings can be made dependent on the current date and time, allowing for use during business and non-business hours.

An UM auto attendent can also be configured for a language other than the default U.S. English, or even for multiple languages. This requires installation of the UM language pack for the desired language. (There’s more on UM language packs later in this chapter.) Enabling a different language for an UM auto attendant will result in different default prompts and will not translate any custom prompts.

You can configure only one language per UM auto attendant. Should your organization require support for multiple languages, you can create a UM auto attendant for each language, with each attached to its extension, and then create a main UM auto attendent to provide a language selection menu. From the language selection, the caller is transferred to the UM auto attendent of the requested language.

Image Caution If you have created an UM auto attendant and are using OCS or Lync Server, you may need to rerun OcsUmUtil.exe tool to provision a contact object in Active Directory before you can access the UM auto attendant. See the “UM Dial Plan” section earlier in this chapter for more information.

Configuring UM Auto Attendent with Exchange Admin Center

To configure an UM auto attendent using the Exchange Admin Center, you navigate to unified messaging image UM dial plans. Select the UM dial plan for which you want to create an UM auto attendant, and click the Edit icon. At the bottom of the dial plan configuration screen, there is a section “UM Auto Attendants.” Here you can manage the UM auto attendants associated with this UM dial plan. Click the + sign to create a new UM auto attendant and enter details such as the name of the UM auto attendant, or voice command settings. It is recommended you leave unchecked the option “Create This Auto Attendant as Enabled,” as you first may want to configure details before the UM auto attendant becomes active.

As with the UM Dial Plan, creating and configuring an UM auto attendant from the Exchange Admin Center is a two-stage process. After creation of the initial object, you need to edit it in order to configure the details (see Figure 8-9), such as:

· General settings, like the access numbers, the language to use for the default prompts, and if the UM auto attendent is to support voice commands.

· Greetings and informational message, the first optionally for business and non-business hours. The default greeting in English is “Welcome, you are connected to Microsoft Exchange.” You can customize this to, for example, “Welcome to Contoso.”

· The designation of business hours on a weekly calendar, with the option to configure holidays.

· A custom menu, optionally voice controlled, to manage call flow and transfer. It is possible to configure a separate menu for business and non-business hours. The menu options will only be synthesized by the UM text-to-speech engine when a default greeting is configured.

· Access to the address book and if the caller is allowed to search the address book based on the current dial plan, the GAL, or by using a specific address list. You can also configure the operator extension number, which is to support the option of escaping the voice-controlled menu and getting a person on the phone, or when the caller does not select an option for a certain period.

· Authorizations for rerouting the caller by the UM auto attendant.


Figure 8-9. Creating and editing an UM auto attendant using Exchange Admin Center

On UM auto attendants, the greetings, informational announcements, and menu options are played when an UM auto attendant is called. When you are happy with the results, you enable the UM auto attendant by clicking the Enable icon from the UM dial plan details screen.

Image Tip Depending on your requirements, the call flow between UM auto attendants can become quite complex. It is recommended you plan the call flow and determine the requirements before implementing the UM auto attendants structure.

Creating a UM Auto Attendant with Exchange Management Shell

To create an UM auto attendant using the Exchange Management Shell, you employ the New-UMAutoAttendant cmdlet or Set-UMAutoAttendant to reconfigure any existing UM auto attendant. For example, to create a speech-enabled UM auto attendant named ‘Contoso AA’ for dial plan ‘Contoso Dial Plan,’ using pilot number 501 but leaving it disabled for further configuration, you use the following:

New-UMAutoAttendant -Name 'Contoso AA' -UMDialPlan 'Contoso Dial Plan'
-PilotIdentifierList 501 -Status Disabled -SpeechEnabled $true

The output of this cmdlet is shown in Figure 8-10.


Figure 8-10. Creating an UM auto attendant using New-UMAutoAttendant

After creating the initial UM auto attendant, you can configure its details by using Set-UMAutoAttendant. Some of the most popular options are:

· AfterHoursKeyMappingEnabled, which specifies if the non-business-hour key mappings are active.

· AfterHoursKeyMapping, which specifies an array of non-business-hour key mappings to use. You can define up to nine items, which are assigned to keys 1-9, as 0 is reserved for operator. Items consist of the menu option, which is converted using the text-to-speech engine, followed by an action such as transferring the call to another extension or UM auto attendant, leaving a voice mail for a specific UM mailbox, or announcing the hours for the business location or business. A timeout action can be configured for when the caller does not select an option, using key ‘-’.

· AfterHoursMainMenuCustomPromptEnabled, which specifies if the non-business-hours custom prompt is enabled.

· AfterHoursMainMenuCustomPromptFilename, which specifies the custom audio file to use as non-business-hours custom prompt, when AfterHoursMainMenuCustomPromptEnabled is $true.

· AfterHoursTransferToOperatorEnabled, which specifies if transfer to the operator is allowed during non-business hours.

· AfterHoursWelcomeGreetingEnabled, which specifies if the greeting is played during non-business hours.

· AfterHoursWelcomeGreetingFilename, which specifies the custom audio file to play as greeting message when AfterHoursWelcomeGreetingEnabled is $true.

· BusinessHoursKeyMappingEnabled, BusinessHoursKeyMapping, BusinessHoursMainMenuCustomPromptEnabled, BusinessHoursMainMenuCustomPromptFilename, BusinessHoursTransferToOperatorEnabled, BusinessHoursWelcomeGreetingEnabled, and BusinessHoursWelcomeGreetingFilename, which configure the equivalent of their AfterHours* counterparts, except that they apply during business hours.

· AllowDialPlanSubscribers, which specifies if subcribers of the associated dial plan are allowed to dial numbers in the same dial plan.

· DTMFFallbackAutoAttendant, which specifies the dual-tone multi-frequency (DTMF) UM auto attendant to use when SpeechEnabled is $true and UM fails three times to recognize the voice input.

· BusinessHoursSchedule, which specifies the business hours. The value is an array of values formatted as <Day>.<Hours>:<Minutes>, where Sunday is day 0. So, 1.13:15 is Monday 13:15.

· HolidaySchedule, which specifies the holiday schedule. On those days, non-business hours are in effect. The schedule is an array of values formatted as ‘Description,<file name for prompt>,<date>[,<end date>]’, where the filename is the name of an imported UM prompt (more on that later). So, ‘Christmas,GreetingChristmas.wav,12/25/2015,12/26/2015’ will result in non-business-hours behavior on December 25, 2015, until December 26, 2015, playing the stored UM prompt GreetingChristmas.wavas greeting message.

· BusinessLocation, which specifies the location to be announced by the UM auto attendant when the business location option has been selected.

· BusinessName, which specifies the name of the business to announce as part of the default *greeting.

· CallSomeoneEnabled, which specifies if the Call Someone feature is enabled, in which case the caller can call someone from directory search.

· ContactRecipientContainer, which specifies the organizational unit to use for directory searches.

· ContactScope, which specifies the scope of directory searches when callers indicate the name of a user to call. Possible values are GlobalAddressList, AddressList, or DialPlan. When set to AddressList, the ContactAddressList needs to be set to the address list used for directory searches.

· ForwardCallsToDefaultMailbox, which when set to $true, forwards all inbound calls headed to the UM auto attendant to the UM-enabled mailbox specified by DefaultMailbox.

· InfoAnnouncementEnabled, which specifies if the informational announcement, indicated by InfoAnnouncementFilename, should be played.

· Language, which specifies the language used by the UM auto attendant.

· MatchedNameSelectionMethod, which specifies the method to differentiate between similar user names. Options are Department, Title, Location, PromptForAlias to prompt for an alias, InheritedFromUMDialPlan to use the UM dial plan setting, or None.

· NameLookupEnabled, which specifies if the caller is allowed to perform directory searches by dialing or saying the name.

· OperatorExtension, which specifies the extension of the operator. When not specified, the operator extension configured on the UM dial plan will be used.

· PilotIdentifierList, which specifies one or more pilot numbers to be used by the UM auto attendant. The pilot numbers should be in E.164 format.

· SendVoiceMsgEnabled, which specifies if the Send Message feature is enabled. in which case the caller is allowed to send voice-mail messages to other UM-enabled users.

· SpeechEnabled, which specifies if the UM auto attendant is speech-enabled.

· Timezone, which specifies the time zone to be used with the UM auto attendant. When not specified, the time zone configured on the Mailbox server is used. TimeZoneName specifies the name to partially match against the built-in list of time-zone specifications.

· WeekStartDay, which specifies the day to be treated as the first day of the week.

Additional Configurations

Assume you want to reconfigure the previously created UM auto attendant ‘Contoso AA.’ First, let’s define the business hours from Monday (day 1, as you do not reconfigure WeekStartDay) to Friday, 8:00 to 18:00, as follows:

Set-UMAutoAttendant -Identity 'Contoso AA' -BusinessHoursSchedule 1.08:00-18:00, 2.08:00-18:00, 3.08:00-18:00, 4.08:00-18:00, 5.08:00-18:00

Now, assume you want to configure Christmas as the holiday schedule, using a custom greeting. You have created a PCM/8 kHz/mono .wav file containing a custom greeting. Before you can use this file in an UM auto attendant, you need to read the file as a byte array and import it usingImport-UMPrompt. This will store the audio file under a given name in the SystemMailbox{e0dc1c29-89c3-4034-b678-e6c29d823ed9}arbitration mailbox.

Image Tip Unlike previous versions of Exchange, where the greeting and informational messages had to be present on all Unified Messaging servers, the custom prompts in Exchange 2013 are imported in the SystemMailbox{e0dc1c29-89c3-4034-b678-e6c29d823ed9}. The prompts can be in one of the following formats: WMA 9.2 (96 kbps/44 kHz/stereo/1pass CBR, WMA9 8 kbps/8 kHz/Mono), or Linear PCM (16 bit/8 kHz). You can import custom prompts using Import-UMPrompt or you can export them using Export-UMPrompt. These custom prompts can be referred to by specifying the filename of the audio prompt in the HolidaySchedule parameter value when using Set-UMAutoAttendant, for example.

[byte[]]$CG = Get-content -Path "c:\UMPrompts\GreetingChristmas.wav'
-Encoding Byte -ReadCount 0
Import-UMPrompt -UMAutoAttendant 'Contoso AA' -PromptFileName 'GreetingChristmas.wav'
-PromptFileData $CG

Image Tip Importing custom prompts for use as greetings in a UM dial plan is identical to importing them for UM auto attendants. In order to configure UM dial plan greetings, you need to specify the filename—for example, as WelcomeGreetingFilename. For example, if you have imported a greeting using the prompt filename ‘welcome.wav,’ you can configure it as a welcome greeting using Set-UMDialPlan -Identity 'Contoso Dial Plan' -WelcomeGreetingEnabled $true -WelcomeGreetingFileName 'welcome.wav'.

The audio file is now stored under the name specified with PromptFileName, 'GreetingChristmas.wav' and can be referenced to from the ‘Contoso AA’ UM auto attendant using this name. So, to configure a holiday schedule for December 25 and 26, employing the previously imported custom UM prompt, you use:

Set-UMAutoAttendant -Identity 'Contoso AA'
-HolidaySchedule 'Christmas,GreetingChristmas.wav,12/25/2015,12/26/2015'

Image Tip HolidaySchedule supports adding and removing values using the Add/Remove hash table. So, to add, for example, New Year’s Day with a figurative NY.wav prompt, you can use:

Set-UMAutoAttendant -Identity 'Contoso AA'
-HolidaySchedule @{Add='New Year,NY.wav,01/01/2015'}.

Creating a Custom Navigation Menu

Suppose you want to create a custom navigation menu for the UM auto attendant that must be active during business hours. You have the options listed in Table 8-1 to choose from.

Table 8-1. UM Auto Attendant Navigation Menu Options




Transfer to extension

’1, Transfer,123’

2nd field is extension.

Transfer to UM auto attendant

’2,Transfer UMAA,,Contoso AA’

3rd field is name of the UM auto attendant.

Leave voice-mail message

’3,Leave VM,,,,,727011cb-a607-4c1c-a46d-6c0adf9a65e7’

7nd field is Mailbox GUID of the UM mailbox to receive the voice mail.

Announce business location


9th field is set to 1.

Announce business hours


10nd field is set to 1.

Optionally, you can play an audio file. Import the UM prompt using Import-UMPrompt, associating it to the UM auto attendant, and specify its name as the 5th field—for example, ‘1,Transfer,,,TransferHelp.wav.’ Use menu option ‘-’ to specify the timeout action that will be selected when the called does not select an option in a timely fashion.

So, suppose you want 1 to transfer the call to sales on extension 201, 2 to transfer the caller to the service desk on 999. When no menu option is selected, the UM auto attend should drop back to extension 001 after playing the UM prompt named Timeout.wav:

Set-UMAutoAttendant -Identity 'Contoso AA' -BusinessHoursKeyMappingEnabled $true
-BusinessHoursKeyMapping @('1,Sales,201', '2,Service Desk,999',

When ready, you can inspect the UM auto attendant configuration using Get-UMAutoAttendant:

Get-UMAutoAttendant -Identity 'Contoso AA' | Format-List:

The output of this cmdlet should be similar to the output shown in Figure 8-11.


Figure 8-11. Viewing UM auto attendant configuration using Get-UMAutoAttendant

When configuration is finished, you can enable the UM auto attendant from the Exchange Admin Center or use Enable-UMAutoAttendant; for example,

Enable-UMAutoAttendant -Identity 'Contoso AA'

UM Language Packs

A UM language pack is a set of installable files that enable using particular languages in UM dial plans or UM auto attendants. An UM language pack contains the following:

· Pre-recorded prompts, such as “After the tone, please record your message. When you’ve finished recording, hang up or press the # key for more options” in the language of the UM language pack.

· Grammar files are used by Mailbox servers to search the directory for given users in the language of the UM language pack. Grammar files are processed by the Mailbox server hosting the arbitration mailbox, and are downloaded by other Mailbox servers. The mailbox assistant, responsible for generation of the grammar files, runs every per day.

· Text-to-speech (TTS) translation, allowing UM to dictate the contents of email, calendar, contact information, and so on to callers in the language of the UM language pack.

· Automatic speech recognition (ASR) support, allowing callers to interact with UM using voice commands in the language of the UM language pack.

· Voice-mail preview support, allowing users to read a transcript of voice-mail messages in a specific language.

UM language packs should be installed as an add-in to Microsoft Exchange Server 2013 and are version-specific. This means you should not install Exchange 2013 RTM language packs on an Exchange 2013 Cumulative Update SP1 installation.

Image Tip An overview of the available Exchange UM language packs, including links to download these packages, can be found at http://bit.ly/Ex2013UMLP.

There are two methods for installing a UM language pack:

1. Run the downloaded UM language pack executable—for example,

UMLanguagePack.nl-NL.exe /IAcceptExchangeServerLicenseTerms

2. Run setup, specifying /AddUmLanguagePack followed by the language codes of the UM language pack to install, using /s to specify the location of the UM language packs. For example,

setup.exe /AddUmLanguagePack:nl-NL /s:c:\UMLanguagePacks /IAcceptExchangeServerLicenseTerms

You can specify multiple language packs to install; for example,

setup.exe /AddUmLanguagePack:nl-NL,de-DE /s:c:\UMLanguagePacks /IAcceptExchangeServerLicenseTerms

Image Caution UM language pack files are installed in:

$exinstall\Unified Messaging\Prompts\<Language Code>

These system prompt files should not be customized.

Be advised that when upgrading Exchange 2013 by installing a new cumulative update, you first need to remove any installed UM language pack. After that, you can upgrade your Exchange Server and consecutively install the UM language pack released for the new version. You can remove a UM language pack by using the Control Panel or Exhange setup, as follows:

setup.exe /RemoveUMLanguagePack: <UmLanguagePackName>


If you want the UM components to support the TLS protocol, you need to install and assign a valid certificate for Exchange 2013 servers performing the UM call routing (CAS servers) and the UM server function (Mailbox servers). The earlier discussion of the UM server role showed how to alter the startup mode of the UM call routing and UM Server using Set-UMCallRouterSettings and Set-UMService, respectively. When you configure those services to utilize TLS, either by configuring StartupMode as TLS or dual mode, you need to assign a valid certificate. Since this certificate will be used by Exchange as well as the IP-PBX—for example, Lync Server 2013—a certificate generated by the internal PKI infrastructure may suffice.

Assume you want to configure startup to TLS mode, supporting TLS connections instead of unencrypted TCP sessions. You try to configure UM startup mode of the UM call router components to TLS; for example,

Get-ClientAccessServer | Set-UMCallRouterSettings -UMStartupMode TLS

You will be presented with a warning notification containing follow-up instructions:

WARNING: Changes to UMStartupMode will only take effect after the Microsoft Exchange Unified Messaging Call Router service is restarted on server <SERVER NAME>. The Microsoft Unified Messaging Call Router service won’t start unless there is a valid TLS certificate.

WARNING: To complete TLS setup, do all of the following: (1) Create a new certificate using the New-ExchangeCertificate cmdlet. (2) Associate this certificate with the server using the Enable-ExchangeCertificate cmdlet. (3) For self-signed certificates, copy this certificate to the UM IP gateway and correctly import it. For CA-signed certificates, correctly import the CA certificate to the UM IP gateway.

Next, you configure the UM server to use TLS as well, as follows:

Get-UMService | Set-UMService -UMStartupMode TLS

You then are presented with the same notification.

Next, you create a certificate request, install it on the the designated UM servers—both UM call router and UM server—and enable the certificate for UM services.

To request a certificate for a server named AMS-EXCH01.contoso.com (the internal FQDN), you can use the Exchange Admin Center, via server > certificates, selecting the server you wish to request the UM certificate for at Select server, followed by clicking the New icon to request the certificate from an internal CA or to create a certificate request for an offline request (see Figure 8-12).


Figure 8-12. Creating a UM certificate request using Exchange Admin Center

Image Caution Exchange UM doesn’t support wildcard certificates with Microsoft Lync Server. Use the server FQDN as the subject name. Alternatively, you can use a valid third-party certificate and import that one on all servers running the UM call router or UM Server components, IP-PBXs, and when Lync is used, other Lync servers as well. When you use a self-signed certificate, you also need to import it on the IP-PBX.

You can use New-ExchangeCertificate from the Exchange Management Shell to create a certificate request—for example, to generate a request for UM on the AMS-EXCH01:

$CR = New-ExchangeCertificate -GenerateRequest -SubjectName "c=NL,o=MyExchangeLabs,cn=ams-exch01.contoso.com" -FriendlyName "AMS-EXCH01 UM"
Set-Content -path "C:\AMS-EXCH01UM.req" -Value $CR

On the Exchange server, you use the command line utility certutil.exe to submit the certificate request to a local certificate authority. You will be asked to pick the certificate authority server to process the certificate request:

certreq.exe -submit -attrib "CertificateTemplate: WebServer"
"c:\AMS-EXCH01UM.req" "c:\AMS-EXCH01UM.cer"

When the certificate request is processed by the certificate authority, and the certificate is stored in a local .cer file, you can import it and enable it for UM in one go, using:

Import-ExchangeCertificate -Server AMS-EXCH01
-FileData ([Byte[]]$(Get-Content -Path "c:\AMS-EXCH01UM.cer" -Encoding byte -ReadCount 0)) | Enable-ExchangeCertificate -Server AMS-EXCH01 -Services UM,UMCallRouter

Image Caution Be sure to enable the certificate for the UM services as well as the UM call routing services where applicable. Enabling the certificate for UM does not enable it for UM call routing services.

When succesful, you restart the UM service (MSExchangeUM) or UM call router (MSExchangeUMCR) service to make the changes effective, as follows:

Get-Service MSExchangeUM* | Restart-Service

The output of these cmdlets to create a certificate request, processing the certificate and assigning them to UM should be similar to the output shown in Figure 8-13.


Figure 8-13. Generating, issuing, and installing a UM certificate

UM Mailbox Management

With UM configured, you can start enabling mailboxes for voice mail and other UM-related features. You can UM-enable a mailbox from the Exchange Admin Center via recipients > mailboxes. Select the user you want to enable for UM, and click Enable in the right pane, where it says “Phone and Voice Features”, as shown in Figure 8-14. If you use the Exchange Admin Center, then enabling mailboxes for UM features is a per-mailbox process.


Figure 8-14. Enabling a mailbox for UM features

The output of this cmdlet should be similar to the output as shown in Figure 8-15.


Figure 8-15. Creating Exchange as a trusted application in Lync

When you UM-enable a mailbox, you need to provide the following information:

· UM Mailbox policy to assign to the mailbox.

· SIP address to assign to the mailbox. This address will also be configured as an additional proxy addres of the type EUM (Exchange Unified Messaging) with the address corresponding to the SIP address configured here.

· Extension number to assign to the mailbox, which depends on the UM dial plan.

· PIN to assign for accessing the mailbox. You can also let Exchange generate a PIN. Optionally, the user can be required to reset the PIN after signing in. When finished, Exchange will send an email containing the extension number, the Outlook voice access number, and the configured PIN to the mailbox for reference.

Image Note Unified messaging requires an Enterprise Client Access License (CAL) for the mailbox.

Lync Server 2013 Integration

Integration of Exchange unified messaging and IP-PBX solutions produces the unified communications experience, something best achieved with Exchange UM in combination with Lync Server. Tight integration makes these products complementary rather than their being connected, individual-point solutions.

In the sections on the UM dial plan and UM IP gateway, it was shown how to connect Exchange UM and OCS or Lync Server via automatic provisioning of Exchange UM configuration objects in Active Directory, using Lync Server configuration information such as the UM IP gateway for Lync creation and using the ExchUcUtil.ps1 script, or the creation of UM contact objects using OcsUmUtil.exe.

Some other integration features are the display of presence information in OWA, instant messaging from OWA, archiving Lync instant messaging messages in your mailbox, and the Unified Contact Store. These require that you define the Exchange servers as trusted application servers in the Lync Front-End pool and configure Exchange to enable Lync-related functionality.

Lync Server Configuration

For each Exchange UM server, you run the following in the Lync Management Shell:

New-CsTrustedApplicationPool -Identity <Exchange UM Server> -ThrottleAsServer $true
-TreatAsAuthenticated $true -ComputerFQDN <Exchange UM Server FQDN> -Site <Site>
-Registrar <Lync FE Pool FQDN> -RequiresReplication $false

The output of this cmdlet should be similar to the output as shown in Figure 8-15.

Next, you define Exchange UM as a trusted application in this pool. This requires a vacant IP port per Exchange UM server; make sure it is free and that traffic on this port between this server and the Lync Front End servers is not blocked:

New-CsTrustedApplication -ApplicationId <Exchange Server Name>
-TrustedApplicationPoolFqdn <Server FQDN> -Port 5170

The output of this cmdlet should be similar to the output as shown in Figure 8-16.


Figure 8-16. Adding Exchange Server as a trusted application to the Trusted Application pool

Next, you configure Exchange as a trusted partner. Note that the URL used is the external Autodiscover URL:

New-CsPartnerApplication -Identity Exchange -ApplicationTrustLevel Full
-MetadataUrl https://autodiscover.contoso.com/autodiscover/metadata/json/1
Set-CsOAuthConfiguration -Identity global
-ExchangeAutodiscoverUrl https://autodiscover.contoso.com/autodiscover/autodiscover.svc

Then, you run Enable-CsTopology to enable these topology changes.

Configuring Exchange Server

First, you run the following scripts from the $exscripts folder on one of the trusted Exchange UM servers, using the Lync Front End pool FQDN; for example,

-AuthMetaDataUrl 'https://ams-lync01.contoso.com/metadata/json/1' -ApplicationType Lync

Next, you reconfigure the Outlook WebApp virtual directories, enabling them for Lync functionality, such as presence indicators and instant messaging from Outlook WebApp. To accomplish this, you need to get the thumbprint of the certificate that is used for UM service. Then, you enable OCS functionality for each OWA virtual directory, providing the thumbprint used by that UM server and the FQDN of the Lync enterprise pool:

$UMThumb= (Get-ExchangeCertificate -server ams-exch01 | Where { $_.Services
-like '*UM*'}).ThumbPrint
Get-OwaVirtualDirectory -server ams-exch01 | Set-OwaVirtualDirectory
-InstantMessagingEnabled $true -InstantMessagingType OCS
-InstantMessagingCertificateThumbprint $UMThumb
–InstantMessagingServerName ams-lync01.contoso.com

With these UM features enabled on OWA, you then enable the related features through the mailbox policy. To enable instant messaging for all defined mailbox policies, for example, you use:

Get-OwaMailboxPolicy | Set-OwaMailboxPolicy -InstantMessagingEnabled $true
–InstantMessagingType OCS

You run the following cmdlets on each Mailbox server to complete the OWA integration, using the Lync Front End pool FQDN. Better yet is to add these cmdlets to a file such as AddOWAIM.ps1, which allows you to run the configuration steps on multiple Mailbox servers by just running the script:

$UMThumb= (Get-ExchangeCertificate | Where { $_.Services -like '*UMCR*'}).ThumbPrint | Select -First 1
$WebConfigFile= join-path $exinstall "ClientAccess\Owa\web.config"
$wc= [XML](Get-Content $WebConfigFile)
$el= $wc.CreateElement("add")
$key= $wc.CreateAttribute( 'key')
$key.psbase.value = 'IMCertificateThumbprint'
$val= $wc.CreateAttribute('value')
$val.psbase.value= $UMThumb
$wc.configuration.appSettings.Appendchild( $el)
$el= $wc.CreateElement("add")
$key= $wc.CreateAttribute( 'key')
$key.psbase.value = 'IMServerName'
$val= $wc.CreateAttribute('value')
$val.psbase.value= 'ams-lync01.contoso.com'
$wc.configuration.appSettings.Appendchild( $el)
$wc.Save( $WebConfigFile)

When running this as a script, the output you receive should be similar to the following:


Figure 8-17. Adding IM integration to OWA web.config

After running this, the web.config file in <Exchange Install Path>\ClientAccess\OWA should have two new entries in the app settings element, as shown in Figure 8-18. If preferred, you can insert these elements manually, using the thumbprint of the certificate assigned to the UM services.


Figure 8-18. Changes in web.config for IM integration

When you are finished configuring, you recycle the OWA app pool and restart the UM services:

Import-Module Web-Administration
Restart-WebAppPool -Name 'MSExchangeOWAWebAppPool'
Get-Service MSExchangeUM* | Restart-Service

Image Caution Installing Exchange 2013 cumulative updates will overwrite these web.config files, requiring you to redo the edits on web.config, as stated above.

After configuring the OWA integration for Lync, you will notice in Outlook WebApp that presence information is displayed with the contacts, and you have the ability to send those contacts an instant message or you can check or update your Lync status information, as displayed inFigure 8-19.


Figure 8-19. Outlook WebApp and Lync integration

Unified Contact Store

The Unified Contact Store allows users to maintain a single Contacts folder and have this information shared among the Outlook client, Outlook WebApp, and the Lync client. When a user is UCS enabled, his Lync contacts are stored in his Exchange mailbox, in a folder named Lync Contacts (see Figure 8-20). This information is retrieved by the Lync client using Exchange Web Services.


Figure 8-20. Unified Contact Store as manifested in Outlook 2013

To enable the Unified Contact Store from the Lync Management Shell, you run the following cmdlets. First, if you want to enable UCS for the default global user policy, you use:

Set-CsUserServicesPolicy -Identity global -UcsAllowed $True

Alternatively, you can create a new policy and enable the UCS setting:

New-CsUserServicesPolicy -Identity "AllowUnifiedContactStore" -UcsAllowed $True

If you created a new policy, you then need to assign users to this new policy for them to enable UCS. For example, to enable UCS for a user named Philip, using the AllowUnifiedContactStore policy, you run the following cmdlet:

Grant-CsUserServicesPolicy -Identity "Ken Myer" -PolicyName "AllowUnifiedContactStore"

To enable UCS for all Lync-enabled users, you run this cmdlet:

Get-CsUser | Grant-CsUserServicesPolicy -PolicyName "AllowUnifiedContactStore"

Exchange Archiving

Lync Server 2013 can be configured to store Lync conversations and conferencing transcripts in Exchange, rather than in the Lync SQL database. When Lync is configured to trust Exchange and vice-versa, you can enable the Exchange archiving by running the following cmdlet from the Lync Management Shell:

Set-CsArchivingConfiguration -Identity 'global' -EnableArchiving ImOnly
-EnableExchangeArchiving $True

Instead of archiving only instant messages using the default ImOnly setting, you can choose not to archive by setting EnableArchiving to None, or to archive instant messages and web conference transcripts by setting it to ImAndWebConf.

Next, you also need to configure what kind of communications to archive, whether internal or external, as archiving for these two types of communications is disabled by default. This status is based in user policy. To configure Lync to archive instant messages exchanged with internal and external partners, you can reconfigure the default global policy by using:

Set-CsArchivingPolicy -Identity 'global' -ArchiveInternal $True -ArchiveExternal $True

When Exchange archiving is enabled, the Exchange archiving policies prevail over the Lync Server archiving policies. However, if Lync and Exchange are hosted in different forests, you must set the Exchange archiving policy on each Lync user object to ArchivingToExchange; for example,

Set-CsUser -Identity philip -ExchangeArchivingPolicy ArchivingToExchange

Call Answering Rules

Rules for call answering enable users to control how inbound calls headed for their voice mail are handled, much in the way inbox rules are established. The settings are per-user and they stored in their mailbox.

Users can manage call answer rules from Outlook or Outlook WebApp. From Outlook WebApp, the call answering rules are accessible through OWA image Options image phone image voice-mail (see Figure 8-21). However, when you are selecting File image Account Information image Voice Mail in Outlook, you will be taken to the same page, as there is no native Outlook interface for managing call answering rules.


Figure 8-21. Accessing call answer rules from Outlook 2013

Besides having a name, each call answering rule consists of conditions and actions. Possible conditions are as follows:

· If (automatic replies are on): when you have activated your out of office (OOF) response.

· My schedule shows that I am. . .: when your current calendar status shows you are free, tentative, busy, or out of office.

· The caller calls me at. . .: allows you to create different rules for each extension you may have configured—that is, different rules when someone calls your public or your private number.

· It’s during this period. . .: lets you create a rule that matches a certain time frame, including working or non-working hours, as defined by Outlook image Options image Calendar image Work Hours.

· The caller is. . .: allows you to create rules for when a specific person, telephone number, or someone from your Contacts folder calls you. The latter allows you to create different rules for people who are in your Contacts folder or those who are not.

· None: applies the rule to all incoming calls.

The caller can be presented with a user-definable menu (see Figure 8-22) whereby caller has the following options:

· Leave a voice-mail message

· Find me

· Transfer the call to a different number


Figure 8-22. Configuring the call answering rules and find me details

Image Caution Menu entries cannot be edited. If you want to make changes, you need to remove the entry and re-add it with the changed options.

Rules are processed in order; the first condition matching a rule fires. If no action is defined, the call is disconnected after the greeting is played.

Image Tip Not every organization fancies the idea of its end users building all sorts of call flows from their mailbox. To disable the call answering rules, administrators can use

Set-UMMailbox <UserID> -CallAnsweringRulesEnabled $false, or reconfigure it for groups of users through their mailbox policy; for example,

Set-UMMailboxPolicy -Identity 'NoCAR Policy' -AllowCallAnsweringRules $false.

To manage the call answering rules remotely, Exchange administrators can use New-UMCallAnswerRule to create new call answering rules using the following parameters:

· Mailbox specifies the UM-enabled mailbox to configure the call answering rule on. If not specified, the mailbox of the currently logged on user is used.

· Name specifies the name of the call answering rule.

· Priority specifies the priority of the rule; lower priority rules are matched first.

· CallersCanInterruptGreeting specifies if callers can interrupt the greeting.

These parameters specify the following conditions:

· CallerIds notes a “If the caller is. . .” condition, and can be a telephone number, contact, or Personal Contacts folder. You can specify up to 50 comma-separated entries.

· CheckAutomaticReplies specifies an “If automatic replies are enabled” condition.

· ExtensionsDialed specifies an “If the caller dials. . .” condition.

· ScheduleStatus specifies a “My schedule shows. . .” condition. This is a bit-masked value, allowing you to mix multiple statuses (anding the values). Possible values are:

· None: 0x0

· Free: 0x1

· Tentative: 0x2

· Busy: 0x4

· Away: 0x8

· TimeOfDay specifies an “It’s during this period” condition.

The parameters specifying actions are:

· KeyMappings specifies one or more key mapping entries offered to callers. Format is <Order>,<Key>,<Name>,,,,,<Number>, so “2,2,Support,,,,,123,” will offer the option to dial support at 123 as a second option by keying in “2.”

These conditions and how the key mappings can be used are best explained by an example. In this call answering rule, you are matching against the following conditions:

· The caller is +311234567890.

· My schedule shows I am busy or away.

· The caller calls me at francis@myexchangelabs.com.

· The caller calls me during working hours.

If all these are true, you provide the caller with the option to:

· Press # to leave a voice message.

To implement this call answering rule on an UM-enabled mailbox named ‘Francis,’ you use the following cmdlet:

New-UMCallAnsweringRule -Mailbox Francis -Name 'My CAR Rue 1'
-CallerIds '1,+311234567890,,,' -ExtensionsDialed 'francis@myexcangelabs.com'
-ScheduleStatus 0x12 -TimeOfDay '1,0,,' -KeyMappings '4,10,,,0,,0,,'

As you can see, with KeyMappings and CallerIds containing values with multiple, comma-separated fields, this is a less friendly way to manage the settings. Therefore, it is recommended instead that you create the rules using the Exchange Control Panel and get the values you need with Get-UMCallAnsweringRules, providing you with information you could use in a script to provision other mailboxes as well.

Voice-Mail Preview

Exchange uses speech-to-text to transcribe the voice-mail message. This transcription is inserted in the body of the voice-mail message. The easiest way to test how voice-mail preview sends voice mail is by using a Lync client, selecting a contact, and selecting Call image Voice Mail (see Figure 8-23).


Figure 8-23. Leaving a voice-mail message

After you leave a voice mail, the recipient will find a voice-mail item in her inbox, which offers some options on top of the regular email choices, such as:

· Play the recorded voice-mail message.

· Play on phone, allowing the user to play her voice-mail message on a phone rather than through her computer’s speakers.

· Add notes to the voice-mail message.

As you can see in Figure 8-24, voice-mail preview contains a transcript of the message. While it’s not guaranteed 100 percent correct, it may help recipients quickly triage unprocessed voice-mail messages in their inbox.


Figure 8-24. Voice-mail message

Image Note Unlike previous versions of Exchange UM, transcription of voice-mail messages now happens to all messages, even if they are over 75 seconds long. If a message is over 75 seconds, it is transcribed, but the text for the message isn’t included.

Outlook Voice Access

Outlook Voice Access (OVA) allows users to call their UM-enabled mailbox to access their voice mail, email, calendar, and contacts information, all using text-to-speech and voice-controlled communications. To access Outlook Voice Access, you call the pilot number configured for OVA,pick the OVA entry from the global address list, or dial your own extension.

When users use OVA, they first need to set up OVA and in doing so, they are given the option of customizing the pronunciation of their names, as well as to record a personal greeting message that is played when the users are busy. Details on which commands OVA understands and instructions for using them can be found at http://bit.ly/OVA2013.


In this chapter, the UM feature set of Exchange 2013 was explored, describing the UM functionality as divided between the Client Access server and the Mailbox server roles.

Then, the chapter introduced how to create and configure the UM configuration objects that are required to integrate Exchange UM with supported IP telephony solutions such as UM dial plans, UM IP gateway objects, and UM hunt groups. We also showed how to use theOcsUMUtil.exe tool to create the initial configuration objects for Exchange UM and Lync integration. Then, we explained how to create and configure the UM mailbox policies, which define the UM features that are available to end users.

We also showed how to create and configure the UM auto attendants to assist end users or inbound callers, offering voice-controlled text-to-speech options for call routing, dialing into user voice mail, or checking mailbox information like the inbox or calendar by using Outlook Voice Access.

Finally, we demonstrated how to integrate Exchange UM with Lync, offering UM features through supported clients, like instant messaging and presence information through Outlook WebApp or presence information through Outlook. Also, specific features of the Exchange UM and Lync combination were discussed, such as the Unified Contact Store, how call answering rules can be used by end users to manage call flow during absence, and how voice-mail preview can help users assess the critical nature of their voice-mail messages.