Apr 25

Cuci-Lync Displaying Calls not Belonging to you

Come across an issue where the customer was complaining their CUCI-lync software agent was displaying calls made to another phone user, effectively another user extension. This gave the CUCI-Lync user the ability to operate the call control fetures for the other extension, like placing the caller on hold, transfer, disconnect the call etc.

The local support team check associated User Device Profiles (UDP) for the CUCI-Lync user, this is done on the End User page on CUCM. This only showed a singel UDP being associated. So how can this be?

Also, in CUCI-Lync settings, the user had selcted only their UDP for CUCI-Lync to control.

Ok, two significant items here. One, I found the user was also associated to a Device. Even though this Device has no line extension enabled, and is solely for Users to log into via EM, CUCI-Lync can still see the Device and also can see the Logged in User. Thats correct, if an EM user logs onto that Device, CUCI-Lync can indeed see that UDP. if CUCI-Lync can see the UDP then it can also see incoming calls to that UDP. Two, by selecting what device to control in the CUCI-Lync settings page, this only sets the Primary Devcie, hence it will use the selected Device or UDP for Outbound calling. However it will see all incomming calls on all devices/UDPs including UDPs that are not directly associated to the User but have logged onto a Device that is associated to a User.

So by removing the Device association from the User, this in effect removed the ability for CUCI-Lync to see incomming calls to the UDP logged onto the Device is question. I hope this makes sense.



Apr 25

Extension Mobility Slow to Log in/out

I come across an issue where EM users were complaining about the log in and out times for Extension Mobility. Essentially the log in time was around 20-30 seconds, log out time a little quicker than that. However in terms of EM this is slow. The log in/out process should take under 5 seconds or thereabouts.

Branch users were also experiencing slower log in/out times than the HQ.

As I was working remotely I used the Uplinx Software Remote Phone Control Tool, this is an awesome
tool, as I can work on the phone and visually experience everything the phone user would. A screen dump below of a phone controlled via The Uplinx Phone Control Tool. Follow the link if you want to check the tool. http://www.uplinx.com/phonecontrol.htm

Uplinx Phone Tool

I connected to a phone and monitored the user logging out of the phone and back in. Yes it was quite slow, but I did see flash up on the screen the phone was initiating a Locale download. This would definitely slow the log in/out process if the phone and/or the Device Profile were always downloading the Locale.

I compared the Device
User Locale, the User Device Profile User Locale and the default User Locale configure in the Enterprise Configuration page. I confirmed the Locales were indeed different. The Device was configured for UK English, the UDP configured with NONE  (which then takes its User Locale from the system) and the System User Locale was set to US English.

I changed the system User Locale to UK English and applied changed. Yes this is a global change; however this issue was affecting users on a system wide basis. I Monitored the EM Log in/out process again and speeds were back to normal.

Changing the User
Locale for a Devices or UDP can be done in bulk via the Bulk Administration Tool and simply using the Update -> Query page for the relevant menu (Device or UDP).

Device Settings - User Locale user locale udp

Enterprise Param - User Locale

Apr 19

Cisco IOS Fax OnRamp

The process of converting inbound faxes to email with TIF attachments provides flexibility, increases efficiency and is a paperless process.

The IOS fax on ramp can direct faxes received by multiple fax numbers to a single email address, or can have a one to one mapping so faxes received on specified fax numbers are sent to its relevant email address.

Cisco also provides a fax off ramp which is not included in this post.

Configuration Steps

1.   Download the fax application from Cisco.com, a valid CCO account is required with a valid support contract associated. The location is under ->Telephony->CME->tcl scripts. The file name app_faxmail_onramp.

2.   Copy this tcl script to the Flash of the ISR.

Hostname#copy tftp://x.x.x.x/ app_faxmail_onramp. flash: app_faxmail_onramp.

3.   Need to enable the ISR to process and forward fax calls.

Hostname(config)#fax interface-type fax-mail

**Must reload the the for changes to take effect.

4.  Need to specify where the ISR can find and reference the tcl script. In the below example the word ‘on-ramp’ is a custom specified WORD. This must match the pots dial-peer service cmd.

Hostname(config)# application

Hostname(config-app)# service on-ramp flash:/app_faxmail_onramp.

5.   Make sure the domain name has been configured on the ISR. The domain name is used when the ISR sends the HELO cmd to the SMTP server.

Hostname(config)#ip domain-name contoso.com

6.   Configure SMTP Server

Hostname(config)#mta send server x.x.x.x port 25

7.   Configure the Subject Line to include both the Calling and Called DNIS or either individually. The Calling DNIS variable is $s$. The Called DNIS variable is $d$

Hostname(config)#mta send with-subject [both | $s$ | $d$]

8.   Configure a sender address. Without this configured, most email servers will reject the email delivery. Do not include the suffix eg @domain.com

Hostname(config)# mta send mail-from username name

9.   Configure the email address suffix (domain name) for the sender. Together with the username (above) this will form a sender email address.

Hostname(config)#mta send mail-from hostname name

10.   Configure Pots Dialpeer to accept inbound fax call from PSTN. When the dialpeer is matched, the service referenced will force the call to be directed to a MMOIP (Multimedia Dialpeer) dialpeer. The MMOIP’s destination-pattern must match the called number. Other configuration in the pots dialpeer are standard

Hostname(config)#dial-peer voice 100 pots

Hostname(config-dial-peer)#description Match Fax Numbers

Hostname(config-dial-peer)#incoming called-number [string eg ^6542711$ or ^654…. Etc]


Hostname(config-dial-peer)#service on-ramp

11.   Configure the MMOIP dialpeer. This is effectively the outbound call leg of the fax call. The MMOIP will connect to the SMTP Server to send the email. Within this dial-peer we can specify the destination email address. The information-type fax allows the MMIOP to communicate to the T.37 fax protocol, without this command the tcl script cannot select this MMOIP dialpeer.

The command service fax_on_vfc_onramp_app out-bound references a script in the fax application when the dial-peer is used for outbound calls. This effectively sends the email.

Commands mdn, dsn success, dsn failure are optional. Determine whether send the originating fax a delivery notification if a fax fails, succeeds or delays.

Hostname(config)#dial-peer voice 101 mmoip

Hostname(config-dial-peer)#desc Outbound to Email

Hostname(config-dial-peer)#destination-pattern [string eg ^6542711$ or ^654….etc]

Hostname(config-dial-peer)# service fax_on_vfc_onramp_app out-bound

Hostname(config-dial-peer)# information-type fax

Hostname(config-dial-peer)# session target mailto:email_address

Hostname(config-dial-peer)# image resolution fine

Hostname(config-dial-peer)# mdn

Hostname(config-dial-peer)# dsn success

Hostname(config-dial-peer)# dsn failure

Mar 21


RSVP is a topology aware Call Admission Control (CAC) mechanism. As with any CAC mechanism the main purpose is to determine whether a call has enough bandwidth to proceed. RSVP supports any network topology and can pass through non-rsvp aware routers. Non-rsvp aware router will ignore and forward all rsvp messages.

RSVP signalling uses the same IP route as the media stream would take. If bandwidth on any link throughout the network is not sufficient, the reservation fails. If there is sufficient bandwidth throughout the network the reservation succeeds.

RSVP calculation

Lets work with G729 codec. Now before I get into how RSVP calculates bandwidth requirements, let do a quick refresher on payload sizes, and rtp stream size requirements for G729.

Below is a quick calculation on the three sampling sizes available for configuration in CUCM and CME.

10ms sampling size
IP Header = 20bytes
UDP Header = 8bytes
RTP Header = 12bytes
Payload = 10bytes
Total 50bytes per packet

1000ms / 10ms (sampling size)  = 100packets per seconds (pps)

100pps x 50bytes = 5000bytes per second

Convert to kbps = 40kbps. This is needed to for a single call with G729 with 10ms sampling size.

20ms sampling (Default for both CUCM and CME)

IP Header 20bytes
UDP Header 8bytes
RTP Header 12bytes
Payload 20bytes
Total 60bytes per packet.

1000ms / 20ms = 50pps

50pps x 60bytes = 3000bytes per second

Convert to kbps = 24kbps. This is needed to for a single call with G729 with 20ms sampling size.

30ms Sampling size

IP Header 20bytes
UDP Header 8bytes
RTP Header 12bytes
Payload 30bytes
Total 70bytes per packet

1000ms / 30ms = 33pps

33pps x 70bytes = 2310bytes per second

Convert to kbps = 18.4kbps. This is needed to for a single call with G729 with 30ms sampling size.

As we can see the 10ms sampling size requires the highest amount of bandwidth being 40kbps. Keep that in mind for a later discussion.

RSVP bandwidth pool is configured on each router’s interface with the ip rsvp bandwidth bandwidth command.

The bandwidth entered should equal the number of calls that is allowed to stream across the interface simultaneously. Working from the default (20ms sampling size), if we want to restrict calls to a maximum of 5 calls, we would enter 136kbps for the bandwidth. You are probably saying, the bandwidth should be 120kbps as 5 x 24kbps equals 120kbps. BUT RSVP doesn’t know the sampling size when the its setting up the reservation. All RSVP knows is the codec type, in this case its G729 which uses a maximum of 40kbps, remember going back to the previous discussion, a 10ms smapling size equals 40kbps. RSVP allows for the maximum size for a G729 call initially, until the rsvp process can look inside the voice stream and determine what sampling size the codec is using. Generally default is left, there the size is 24kbps, RSVP then throttles down the bandwidth needed to 24kbps. Therefore we always add 16kbps (the difference between a 20mx sampling size packet to a 10ms sampling size packet) to the rsvp bandwidth. This allows the last call to be initiated at 40kbps, before being throttled down. If we didn’t add the 16kbps onto the bandwidth needed, the last call would never be allowed to be setup as the RSVP process would have 24kbps left in the bandwidth pool, but 40kbps is needed to initially setup the reservation.

RSVP for CAC purposes is a DiffServ Model, not InetServ model. Yes RSVP traditionally speaking is an InetServ model as the RSVP process sits on the Control and Data Plane of the router. However RSVP used by CUCM sits only on the Control Plane, hence controls the Call Admission Component and not the actual QoS which runs on the Data Plane level. The QoS is left up to the LLQ mechanism.

Configuring RSVP


Interface G0/0
ip rsvp bandwidth kbps
 Dspfarm profile 2 mtp
Codec g729
Codec pass-through
Maximum sessions software 4 (Ensure this number is greater than or equal to the number of  calls desired.

 Sccp local Loopback 0
Sccp ccm identifier 1 version 7+
Sccp ccm identifier 2 version 7+

 Sccp ccm group 1
 Bind interface loopback 0
 Associate ccm 1 priority 1
 Associate ccm 2 priority 2
 Associate profile 2 register HQ-RSVP


*Can only use one codec assigned to an MTP resource, although you can have variations of the codec in same MTP resource. Eg G729a G729ab etc

*The MTP resource can also be used for other purposes, not just rsvp. So its always a good idea to allow maximum sessions higher to what is allowed by RSVP CAC as other process maybe using ghe MTP resource and consuming a session.

Mar 16

Displaying Logged in Users and their Devices using CUCM Shell

We all know in CUCM we can find logged in Users by clicking on the Device Tab then selecting the  Active Logged in Users dropdown on the top right of the window. This displays a list of currently logged in users and what device they have logged onto. To do this in the shell so we can export to a text or CSV file run the following command

run sql select d.name, eu.userid, p.name from extensionmobilitydynamic emd, device d, device p, enduser eu where emd.fkdevice=d.pkid and emd.fkdevice_currentloginprofile=p.pkid and emd.fkenduser=eu.pkid

This will output currently logged on profiles and their relating device. If we just wanted show output for a particular user, for example John Doe, with userid jdoe. We would run the following.

run sql select d.name, eu.userid, p.name from extensionmobilitydynamic emd, device d, device p, enduser eu where emd.fkdevice=d.pkid and emd.fkdevice_currentloginprofile=p.pkid and emd.fkenduser=eu.pkid and eu.userid=jdoe

This will show the following columns: Device Name, User ID, UDP Profile Name

If you would like to add in the DN, simply include the relevant dnorpattern fields.

Let’s take this a step further. Let’s say we are migrating to a new CUCM Cluster and we need to login users to the phones they were logged into on the existing CUCM Cluster.

Once we have this output, we can convert to CSV via the Import Data functionality in Excel, I use space as a separator, then bring together the UDP Profile name with a simply Excel formula. Now we merge the data into the EM Login URL. The URL is below


Simply reference the EM login URLs with a scripting language of your choice and run against the new CUCM Cluster. Users will be auto logged into their phone

Mar 14

Remove Duplicate IP Phone Services in CUCM


In CUCM if we add update UDP’s or devices with Extension Mobility IP Phone Services subscribed, the import process appends another IP Phone Service, so you could end up with multiple IP Phones Services subscribed. Hence when the phone user press the Services button on the IP Phone, the menu displays more than one instance of the IP Phone Service, in this case Extension Mobility.

One way to prevent the IP Phones Services from being duplicated or appended to the Device or UDP is to make sure the import process deletes all IP Phones Services before adding the IP Phone Service from your CSV or TXT file.

Under Override Options check the box “Override the existing configuration”

Then check the box Delete all existing Subscribed Services before adding new ones”

Override Options

If you already have duplicate IP Phone Services subscribed to Devices to UDPs. Go to the Bulk Administration Menu and select the Devices (or UDP) then select Update Phones. Use Update via Query.

Remove Duplicate

If you then check the phones or UDPs, you will now only have one subscription of the IP Phone Service.

Mar 03

IOS Dial Peer Pattern Matching

Thought I would post this topic as I know I tend to forget the many patterns and wildcards that can be used in IOS to march dial peer patterns and translation patterns for that fact. Some patterns are more common that others, however for the lab exam, Im sure the questions will have you creating more complex patterns to test your knowledge.

Patterns used in IOS

  • 0-9 A-D * # These are standard DTMF characters used in IOS.
  • . wildcard that matches any single digit. Important to note the . does not match the * or the #
  • +  can be used if first character to indicate +E164 dialling (IOS 12.4.20 – first introduced)
  • + regex that means one or more of the previous character if not first in string
  • ? regex that means zero or one of the previous character
  • % regex that means zero or more of the previous character
  • ^ regex that means beginning of line
  • $ regex that means end of line
  • T wait for interdigit timeout (only used in IOS). This combined with the . matches all numbers Example .T
  • \ escape next character to use as literal character
  • [] range of digits. Example [2-4]66 means 266 or 366 or 466
  • () a collected pattern of digits (normally used with regex) (100)?55511 could mean
    55511 or 10055511

Let me know if you would like examples of patterns and I will add to post.

Mar 03

Matching Dial Peers VOIP and POTS

Quick note on how Cisco IOS matches dial peers. A single dial peer can be used for both inbound and outbound call legs. The rule destination-pattern can be used for both inbound and outbound dial peer matching, but remember destination-pattern match the calling number (ANI) for inbound call legs and matches the called number (DNIS) for outbound call legs.

Matching Inbound Dial Peer for both VOIP and POTS

  • incoming called-number – Matches called number (DNIS)
  • answer-address – Matches calling number (ANI)
  • destination-pattern – matches calling number (ANI)
  • port – Matches inbound Port  (POTS ONLY)
  • Default dial peer – used with VOIP dial peer ONLY


Default Dial Peer matches the below

  • Any codec
  • VAD enabled
  • No DTMF
  • DSCP 0
  • No RSVP
  • No TCL or VXML Applications
  • No DID


Matching Outbound Call Leg

  • destination-pattern – Matches called number (DNIS)
Mar 02

Disabling PIN for MS Exchange VoiceMail

A popular integration is with using Microsoft Excahnge 2010 as voicemail as opposed to using CUE or CUC. In CUC and CUE a simple check box allows you to effectively disable the PIN (for internal only). However with MS Exchange 2010, there is no GUI option so its to the Exchange Management Shelll (Powershell) we go.

First thing to do is query the user’s mailbox to check the settings. IN particular we are looking for the option “PinlessAccessToVoiceMailEnabled”.

get-ummailbox -identity “emailaddress” | fl PinlessAccessToVoiceMailEnabled

If the mailbox does have a PIN enforced, the results will show “FALSE”

To disable the PIN on the mailbox type the following

set-ummailbox –identity email address –PinlessAccessToVoiceMailEnabled $true

Remember this only applies to internal access. Does not apply to accessing your voicemail from an external device. Also this does not apply to accessing our calendar or email via the phone system, you will need a PIN to access these areas of the MS Exchange 2010 Unified Comms.