Some time ago, I needed to configure an SIP trunk between a Trixbox/FreePBX (Asterisk on Linux) PBX and a Cisco Call Manager PBX. It was pretty hard to find any relevant information on the internet, however eventually I figured out how to do it. Originally this article was written for Trixbox, however the same configuration applies to FreePBX (with minor differences in steps due to the UI differences).
Please note that the following configuration reflects a Trixbox/FreePBX PBX configured with phones with extensions of 1XX and the Cisco Unified Call Manager configured with extensions of 3XX.
If you are simply using CUCM for Cisco IP Phone handset connectivity, you don’t even need CUCM anymore, you can simply use the commercial “EndPoint Manager” on FreePBX to handle Cisco IP Phone connectivity to FreePBX (includes the Cisco 7961 phone’s I use).
Outgoing Settings
Trunk Name: CallManager
Peer Details:
type=friend
qualify=yes
nat=no
insecure=very
host=ip.address.of.CUCM
fromdomain=ip.address.of.CUCM
dtmf=rfc2833
disallow=all
context=from-internal
canreinvite=no
allow=ulaw
Incoming Settings
USER Context: ip.address.of.CUCM
USER Details:
type=friend
qualify=yes
nat=no
insecure=very
host= ip.address.of.CUCM
fromdomain= ip.address.of.CUCM
dtmf=rfc2833
disallow=all
context=from-internal
canreinvite=no
allow=ulaw
Create outbound route “Cisco”. Check the “Intra Company Route”, and inside of the Dial Patterns type in 3XX. Under Trunk Sequence select “CallManager”.
This pretty much sums up the amount of configuration required on the Trixbox/FreePBX side of things. Now onto the Cisco stuff.
Cisco Unified Call Manager Configuration
Create an SIP Trunk
Device -> Trunk -> Add New
Trunk Type: SIP Trunk
Device Protocol: SIP
Device Name: TrixboxPBX
Call Classification: OnNet
Check the “Media Termination Point Required” checkbox (this is to handle transfers, hold music, etc…)
Check “Remote-Party-Id”
Check “Asserted-Identity”
SIP Information
Destination Address: IP.address.of.trixboxfreepbx
Uncheck “Destination Address is an SRV”
Destination Port: 5060
MTP Preferred Originating Code: 711ulaw
SIP Trunk Security Profile: Non-Secure SIP Trunk Profile
System -> Security Profile -> SIP Trunk Security Profile
Hit the “Find” button
Select “Non Secure SIP Trunk Profile”
Incoming Transport Type: TCP+UDP
Outgoing Transport Type: UDP
Uncheck “Enable Digest Authentication”
Incoming Port: 5060
Out of the last 6 checkboxes, all should be checked except the First and Last.
Call Routing -> Route/Hunt -> Route Pattern
Create New
Route Pattern: 1XX
Gateway/Route List: TrixboxPBX
Route Option: Route this pattern
Call Classification: OnNet
I’m not too sure which ones are actually required, however the below configuration works great. To get to the CUCM services go to the “Cisco Unified Serviceability” section (Top right of web interface).
Enable Services
Tools -> Serviceability
Enable the following:
CM Services
Cisco CallManager
Cisco Tftp
Cisco Messaging Interface
Cisco Unified Mobile Voice Access Service
Cisco IP Voice Media Streaming App
CTI Services
Cisco CallManager Attendant Console Server
Cisco IP Manager Assistant
Cisco WebDialer Web Service
Select “Save”, afterwards select “Set to Default”. Please note that it may take some time to bring the services up.
It’s always a good idea to restart both the Trixbox/FreePBX PBX and the CUCM PBX.
After you have configured the above, configure phones in the 1XX range for the trixbox, configure phones on the CUCM for the 3XX range and they should be able to call each other. Please remember that if you have a PSTN line on your Trixbox or FreePBX you will need to create another route pattern for how to transfer 9XXXXXXXXXX from your CUCM -> Trixbox, then configure the applicable route in Trixbox -> PSTN.
Feedback is welcome, leave a comment!
While most of us frequently deploy new ESXi hosts, a question and task not oftenly discussed is how to properly decommission a VMware ESXi host. Some might be surprised to… Read More
This guide will outline the instructions to Disable the VMware Horizon Session Bar. These instructions can be used to disable the Horizon Session Bar (also known as the Horizon Client… Read More
Normally, any VMs that are NVIDIA vGPU enabled have to be manually migrated with manual vMotion if a host is placed in to maintenance mode, to evacuate the host. While… Read More
You may experience GPU issues with the VMware Horizon Indirect Display Driver in your environment when using 3rd party applications which incorrectly utilize the incorrect display adapter. This results with… Read More
Today we're going to cover a powerful little NAS being used with VMware; the Synology DS923+ VMware vSphere Use case and Configuration. This little (but powerful) NAS is perfect for… Read More
Today we'll go over how to install the vSphere vCenter Root Certificate on your client system. Certificates are designed to verify the identity of the systems, software, and/or resources we… Read More
View Comments
Excellent explanation, as you said that there is almost none information about this configuration, i´ve been testing different confs and the only one that works is your conf, but i have a problem because it works only in the way CCM-> Tribox and in the opossite way it doesnt and i hear the record "All ciruits are busy now please try your call again later".
Well i´ll try to find the problem and i´ll send my feedback.
Thanks a lot for share your info
I have to apologize for the late feedback! For some reason I didn't receive an e-mail notification on your comment...
I'm not too sure if you have this checked/enabled, but inside of the web interface, under "PBX Settings", then "General Settings" look for the "Allow anonymous inbound connections" and set it to yes.
Let me know if this works, if not let me know and I'll do some more research in to it!
Thanks for the comment by the way!
(P.S. Make sure you check you inbound routes, etc... so the calls get come into the Trixbox and get terminated on an extension!)
My friend, these are the best set of instructions so far.. I am so close, i can taste it..
I am a Noob.. and am coming at this blind...
The trunk between the CCM and Trixbox
I can't however get the calls to go between the Trixbox and the CCM
I already have the CCM setup with extentiosn using the 65xx format
On Trixbox i'd like to mirror the extentions OR have 165xx as the extention number..
Basically our CCM goes out of an ISDN30, and what i'd like users to be able to do, is if the user is at home, have them connect to the Trixbox, dial 7 to divert outgoing calls out via the isdn30, or dial 8 to divert outgoing calls via a sipgateway (lets say for the sake of example sipgate.co.uk) the users should also be able to dial the 65XX extentions as well and get to people in the office..
The main reason for the use of Trixbox, is we use a product called Trusted Client for home users, which is Ubuntu based, and i can use X-Lite simply make calls over our VPN.. It also provides me with a backup phone system if/when the ISDN30 goes down, which it has 4 times this year..
Any assistance, help, direction will be taken on board.. I'm still earning,but nearly there.
Well I'm glad to hear I can help!
Let me check out my config and play around with a few things and get back to you.
So I just want to confirm, can you make internal calls from CCM -> Trixbox, and Trixbox -> CCM? Or is it just Trixbox -> CCM -> PSTN that isn't working?
You could probably get all extensions (Trixbox and CCM) going on 65XX, however one would have to be 6500-6550 and the other would have to be 6551 to 6599.
Also, tell me if you have "Allow anonymous calls" setup on your Trixbox general config enabled. This could be it. If not, try it out, it might work.
If you do have one way calling from either the CCM or Trixbox to the other, let me know.
Stephen
Hi there, since posting yesterday, i setup the dial plan correctly, and am able to make calls out of the Trixbox to the big wide world VIA the Cisco CCUM..
I'd like to make CCM -> Trixbox, and Trixbox -> CCM?
Tried “Allow anonymous calls” both settings, no change..
Oh, well I'm glad to hear.
I guess if you had the CUCM handling the PSTN the dialplan would be different. In my scenario the Trixbox handled PSTN termination.
Glad to hear you got it going though :)
Stephen
I followed your instructions and it's working CCM -> Trixbox but not the other way around. I enabled “Allow anonymous calls” but it's not working yet. Do you have any further suggestions?
Thanks in advanced....
BTW, great tutorial!!!!!!
Did you configure your outbound dial plans on Trixbox?
Stephen
be sure that you select Calling Search Space that match to your phone in Inbound Calls part of
Trunk Configuration in CUCM
This solves "all circuits are busy" problem for me.
btw great tutorial
Hi Jepes,
Thanks!
jepes could you help me with the Calling Search Space, what is the right config at this?
Thanks
Ronald,
I've noticed no one's replied. I checked my "Calling Search Space" to see what my config is, however I have nothing configured inside of there.
Mind explaining your exact issue? I'll try to help out if I can.
Stephen
I managed to make a call from a my mobile phone through a PRI connect to cisco5300 to an extension on the trixbox. Thanks very much for the info. It was not easy to find this .
Hi
Do you have the command line cli instruction for cme to connect to asterisk using sip. For example what command enables Media Termination Point Required using ios?
Can you forward me your copy of your config? Thanks again.
Hi Mike,
I'm sorry but I did all the above configuration in the web interface. I would have absolutely no idea how to do this using the cli.
Sorry about that. Can anyone else help Mike out?
Hi Stephen,
What is extensions.conf setting? I have followed every steps but it doesn't work for me :(
BTW you did a great work :)
Thanks ShUaib,
Are you referring to the extensions.conf on the trixbox side? I actually don't think I modified any .conf files directly. All configuration was done inside of the Web interface for trixbox itself.
Make sure you check your outbound and inbound routes to make sure they are routing the calls properly. Also, have you verified the boxes are even talking to eachother?
Stephen
Hi Stephen absolutely fabulous work!!! Whilst i have got everything to work. The only thing im struggling with is calls from the PSTN>Trixbox>CUCM. Calls from the PSTN work fine to TrixBox but i just can't figure out how to get TrixBox to forward calls to an extension in CUCM. Any ideas?
Hey Shawn,
Glad I could help! Just curious, can you call from Trixbox extensions to your CUCM extensions? If that's the case, everything is working and you just need to setup your ring groups, etc... For example, when someone calls my general in line, it rings 3 extensions on the tribox, and 3 extensions on the CUCM. Whoever picks up when it rings takes the call...
Now if your actually having trouble calling the CUCM extensions from a Trixbox extension, that means your having some difficulties with communication (ie, theres a bug in the config).
Let me know if this works, or your need anything else.
Thanks,
Stephen