Using FreePBX as an SBC between Voip.MS and Cisco UCM

Hi all,

I just installed the FreePBX distro to replace a Trixbox CE system since this has a newer version of Asterisk

I’m trying to get calls from my Cisco Call Manager SIP trunk to go out to the VOIP.ms trunk. The VOIP.MS trunk works as I have an ATA registered to FreePBX and I can call out no problem. Also incoming calls from VOIP.MS go to the Cisco trunk and they ring my Cisco phones no problem.

The problem is dialing outbound from Cisco phones to UCM which then goes to FreePBX and then out the Voip.MS trunk.

Here’s my trunk details for the Cisco trunk:

Peer Details:

type=peer
host=192.168.10.200
insecure=very
qualify=yes

User context: from-internal

User details:

type=friend
qualify=yes
nat=no
insecure=very
host=192.168.10.200
fromdomain=192.168.10.200
dtmf=rfc2833
canreinvite=yes

Here’s the log files from what happens when I try to dial *97 from CUCM

[2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Executing [*[email protected]:1] Set("SIP/CUCM8-0000001b", "GROUP()=OUT_3") in new stack [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Executing [*[email protected]:2] Goto("SIP/CUCM8-0000001b", "from-trunk,*97,1") in new stack [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Goto (from-trunk,*97,1) [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Executing [*[email protected]:1] Set("SIP/CUCM8-0000001b", "__FROM_DID=*97") in new stack [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Executing [*[email protected]:2] NoOp("SIP/CUCM8-0000001b", "Received an unknown call with DID set to *97") in new stack [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Executing [*[email protected]:3] Goto("SIP/CUCM8-0000001b", "s,a2") in new stack [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Goto (from-trunk,s,2) [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Executing [[email protected]:2] Answer("SIP/CUCM8-0000001b", "") in new stack [2012-10-23 18:11:19] WARNING[3417] chan_sip.c: Ignoring video media offer because port number is zero [2012-10-23 18:11:19] VERBOSE[7324] pbx.c: -- Executing [[email protected]:3] Wait("SIP/CUCM8-0000001b", "2") in new stack [2012-10-23 18:11:19] NOTICE[7324] channel.c: Dropping incompatible voice frame on SIP/CUCM8-0000001b of format ilbc since our native format has changed to 0x1000 (g722) [2012-10-23 18:11:21] VERBOSE[7324] pbx.c: -- Executing [[email protected]:4] Playback("SIP/CUCM8-0000001b", "ss-noservice") in new stack [2012-10-23 18:11:21] VERBOSE[7324] file.c: -- <SIP/CUCM8-0000001b> Playing 'ss-noservice.ulaw' (language 'en') [2012-10-23 18:11:22] VERBOSE[7324] pbx.c: == Spawn extension (from-trunk, s, 4) exited non-zero on 'SIP/CUCM8-0000001b' [2012-10-23 18:11:22] VERBOSE[7324] pbx.c: -- Executing [[email protected]:1] Macro("SIP/CUCM8-0000001b", "hangupcall,") in new stack [2012-10-23 18:11:22] VERBOSE[7324] pbx.c: -- Executing [[email protected]:1] GotoIf("SIP/CUCM8-0000001b", "1?theend") in new stack [2012-10-23 18:11:22] VERBOSE[7324] pbx.c: -- Goto (macro-hangupcall,s,3) [2012-10-23 18:11:22] VERBOSE[7324] pbx.c: -- Executing [[email protected]:3] ExecIf("SIP/CUCM8-0000001b", "0?Set(CDR(recordingfile)=)") in new stack [2012-10-23 18:11:22] VERBOSE[7324] pbx.c: -- Executing [[email protected]:4] Hangup("SIP/CUCM8-0000001b", "") in new stack [2012-10-23 18:11:22] VERBOSE[7324] app_macro.c: == Spawn extension (macro-hangupcall, s, 4) exited non-zero on 'SIP/CUCM8-0000001b' in macro 'hangupcall' [2012-10-23 18:11:22] VERBOSE[7324] pbx.c: == Spawn extension (from-trunk, h, 1) exited non-zero on 'SIP/CUCM8-0000001b'

I do have *97 as Dial Pattern in my Voip.MS Outbound route.

I did some testing and made a Inbound Route with DID *97 with destination Voip.MS and that did work but I’ve never had to do that for when I had Trixbox.

Any ideas on how to get any call from CUCM to go out the VOIP.MS trunk without the Inbound Route setting?

Any help would be apprecticated.

Thanks,

Andrew

You don’t need to declare the same peer twice, use type=friend and put everything in peer details.

Add the line context=from-internal and you will be cooking with gas.

Man, I feel stupid for that, haha. I was always thinking in the way of incoming and outgoing settings being different for the trunk. That was easy.

Thanks so much for that! Lesson learned for me.

Nope only if the peer is different (like a carrier has different inbound and outbound servers), else you are creating a duplicate peer.

Also Asterisk is not a SBC, it’s a Back to Back User Agent. An SBC performs different functions in a SIP network.

Ah, my mistake.

Thanks again!