New SIP Trunk can't get inbound calls to work

Hey guys, running FreePBX v2.10.1.9 with Asterisk v 10.12.0. I’ve just got done installing a new BrightHouse SIP Trunk here in Central Florida. Outbound works like a champ but I’m having issues getting my Inbound DID to route properly to my extensions.

Goal: To dial 386-xxx-4723 and have it ring a phone with the directory number 4723.

Here is my configuration:
SIP Trunk:
Trunk Name: BrightHouse
Outbound CallerID: 386xxxxxxx
Dialed Number Manipulation Rules
(prepend) + 8 | 411
(prepend) + prefix | 911
(prepend) + 8 | 911
(prepend) + 8 | NXXNXXXXXX
(prepend) + 8 | 1NXXNXXXXXX

Outgoing Settings
Trunk Name: BrightHouse
PEER Details:
type=peer
qualify=300
progressinbound=yes
outboundproxy=72.31.114.162
nat=yes
host=72.31.114.162
dtmfmode=rfc2833
disallow=all
canreinvite=yes
allow=ulaw

Incoming Settings
All Blank

Inbound Route
Description: test2
DID Number 386xxx4723
CallerID Number: 386xxx4723
Set Destination
Extensions <4723> 4723

That the extent of my configuration:

This is the SIP debug that shows it can’t find the number 386xxx4723 and plays the service message: ss-noservice

With my limited knowledge of Asterisk it sounds like a context issue?

<— SIP read from UDP:72.31.114.162:5060 —>
INVITE sip:[email protected]:5060 SIP/2.0
Via: SIP/2.0/UDP 72.31.114.162:5060;branch=z9hG4bKvmnvl902r669u1nrmdavvbkr10
To: sip:[email protected]
From: “Cell Phone CA” sip:[email protected];user=phone;tag=snl_0029258532_NSN_CLIENT
Call-ID: NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315
CSeq: 1235 INVITE
Contact: sip:[email protected]:5060;maddr=72.31.114.162;transport=udp
Content-Type: application/sdp
Content-Length: 172
Accept-Language: en;q=0.0
Allow: REGISTER, INVITE, ACK, BYE, CANCEL, NOTIFY, REFER, PRACK
Supported: 100rel
Supported: timer
Session-Expires: 1800;refresher=uac
Min-SE: 1800
Date: Mon, 15 Apr 2013 20:18:59 GMT
Max-Forwards: 62
P-Asserted-Identity: “Cell Phone CA” sip:[email protected];user=phone
Privacy: none

v=0
o=- 561743976 0 IN IP4 72.31.114.162
s=-
c=IN IP4 72.31.114.162
t=0 0
m=audio 26262 RTP/AVP 0 101
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:20
<------------->
— (19 headers 9 lines) —
Sending to 72.31.114.162:5060 (NAT)
Using INVITE request as basis request - NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315
Found peer ‘BrightHouse’ for ‘310xxxyyyy’ from 72.31.114.162:5060
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
Found RTP audio format 0
Found RTP audio format 101
Found audio description format telephone-event for ID 101
Capabilities: us - (ulaw), peer - audio=(ulaw)/video=(nothing)/text=(nothing), combined - (ulaw)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1 (telephone-event|), combined - 0x1 (telephone-event|)
Peer audio RTP is at port 72.31.114.162:26262
Looking for 386xxx4723 in from-trunk-sip-BrightHouse (domain 172.19.55.2)
list_route: hop: sip:[email protected]:5060;maddr=72.31.114.162;transport=udp

<— Transmitting (NAT) to 72.31.114.162:5060 —>
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 72.31.114.162:5060;branch=z9hG4bKvmnvl902r669u1nrmdavvbkr10;received=72.31.114.162;rport=5060
From: “Cell Phone CA” sip:[email protected];user=phone;tag=snl_0029258532_NSN_CLIENT
To: sip:[email protected]
Call-ID: NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315
CSeq: 1235 INVITE
Server: FPBX-2.10.1(10.12.0)
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Contact: sip:[email protected]:5060
Content-Length: 0

<------------>
– Executing [[email protected]:1] Set(“SIP/BrightHouse-00000033”, “GROUP()=OUT_2”) in new stack
– Executing [[email protected]:2] Goto(“SIP/BrightHouse-00000033”, “from-trunk,386xxx4723,1”) in new stack
– Goto (from-trunk,386xxx4723,1)
– Executing [[email protected]:1] Set(“SIP/BrightHouse-00000033”, “__FROM_DID=386xxx4723”) in new stack
– Executing [[email protected]:2] NoOp(“SIP/BrightHouse-00000033”, “Received an unknown call with DID set to 386xxx4723”) in new stack
– Executing [[email protected]:3] Goto(“SIP/BrightHouse-00000033”, “s,a2”) in new stack
– Goto (from-trunk,s,2)
– Executing [[email protected]:2] Answer(“SIP/BrightHouse-00000033”, “”) in new stack
Audio is at 16754
Adding codec 100003 (ulaw) to SDP
Adding non-codec 0x1 (telephone-event) to SDP

<— Reliably Transmitting (NAT) to 72.31.114.162:5060 —>
SIP/2.0 200 OK
Via: SIP/2.0/UDP 72.31.114.162:5060;branch=z9hG4bKvmnvl902r669u1nrmdavvbkr10;received=72.31.114.162;rport=5060
From: “Cell Phone CA” sip:[email protected];user=phone;tag=snl_0029258532_NSN_CLIENT
To: sip:[email protected];tag=as0cf2391e
Call-ID: NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315
CSeq: 1235 INVITE
Server: FPBX-2.10.1(10.12.0)
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Contact: sip:[email protected]:5060
Content-Type: application/sdp
Content-Length: 234

v=0
o=root 1305829573 1305829573 IN IP4 172.19.55.2
s=Asterisk PBX 10.12.0
c=IN IP4 172.19.55.2
t=0 0
m=audio 16754 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv

<------------>

<— SIP read from UDP:72.31.114.162:5060 —>
ACK sip:[email protected]:5060 SIP/2.0
Via: SIP/2.0/UDP 72.31.114.162:5060;branch=z9hG4bK2csbcbao92rc9ktaibkki9nrc3-8g9j5
To: sip:[email protected];tag=as0cf2391e
From: sip:[email protected];user=phone;otg=6;tag=snl_0029258532_NSN_CLIENT
Call-ID: NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315
CSeq: 1235 ACK
Contact: sip:[email protected]:5060;maddr=72.31.114.162;transport=udp
Date: Mon, 15 Apr 2013 20:18:59 GMT
Max-Forwards: 62
Content-Length: 0

<------------->
— (10 headers 0 lines) —
– Executing [[email protected]:3] Wait(“SIP/BrightHouse-00000033”, “2”) in new stack
– Executing [[email protected]:4] Playback(“SIP/BrightHouse-00000033”, “ss-noservice”) in new stack
– <SIP/BrightHouse-00000033> Playing ‘ss-noservice.ulaw’ (language ‘en’)
– Executing [[email protected]:5] SayAlpha(“SIP/BrightHouse-00000033”, “386xxx4723”) in new stack
– <SIP/BrightHouse-00000033> Playing ‘digits/3.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/8.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/6.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/x.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/x.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/x.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/4.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/7.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/2.ulaw’ (language ‘en’)
– <SIP/BrightHouse-00000033> Playing ‘digits/3.ulaw’ (language ‘en’)
– Executing [[email protected]:6] Hangup(“SIP/BrightHouse-00000033”, “”) in new stack
== Spawn extension (from-trunk, s, 6) exited non-zero on ‘SIP/BrightHouse-00000033’
– Executing [[email protected]:1] Macro(“SIP/BrightHouse-00000033”, “hangupcall,”) in new stack
– Executing [[email protected]:1] GotoIf(“SIP/BrightHouse-00000033”, “1?theend”) in new stack
– Goto (macro-hangupcall,s,3)
– Executing [[email protected]:3] ExecIf(“SIP/BrightHouse-00000033”, “0?Set(CDR(recordingfile)=)”) in new stack
– Executing [[email protected]:4] Hangup(“SIP/BrightHouse-00000033”, “”) in new stack
== Spawn extension (macro-hangupcall, s, 4) exited non-zero on ‘SIP/BrightHouse-00000033’ in macro ‘hangupcall’
== Spawn extension (from-trunk, h, 1) exited non-zero on 'SIP/BrightHouse-00000033’
Scheduling destruction of SIP dialog ‘NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315’ in 6400 ms (Method: ACK)
set_destination: Parsing sip:[email protected]:5060;maddr=72.31.114.162;transport=udp for address/port to send to
set_destination: set destination to 72.31.114.162:5060
Reliably Transmitting (NAT) to 72.31.114.162:5060:
BYE sip:[email protected]:5060;maddr=72.31.114.162;transport=udp SIP/2.0
Via: SIP/2.0/UDP 172.19.55.2:5060;branch=z9hG4bK5100be29;rport
Max-Forwards: 70
From: sip:[email protected];tag=as0cf2391e
To: “Cell Phone CA” sip:[email protected];user=phone;tag=snl_0029258532_NSN_CLIENT
Call-ID: NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315
CSeq: 102 BYE
User-Agent: FPBX-2.10.1(10.12.0)
X-Asterisk-HangupCause: Normal Clearing
X-Asterisk-HangupCauseCode: 16
Content-Length: 0


<— SIP read from UDP:72.31.114.162:5060 —>
SIP/2.0 200 OK
Via: SIP/2.0/UDP 172.19.55.2:5060;received=71.43.192.30;branch=z9hG4bK5100be29;rport=5060
From: sip:[email protected];tag=as0cf2391e
To: “Cell Phone CA” sip:[email protected];user=phone;tag=snl_0029258532_NSN_CLIENT
Call-ID: NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315
CSeq: 102 BYE
Contact: sip:[email protected]:5060;maddr=72.31.114.162;transport=udp
Date: Mon, 15 Apr 2013 20:19:12 GMT
Content-Length: 0

<------------->
— (9 headers 0 lines) —
SIP Response message for INCOMING dialog BYE arrived
Really destroying SIP dialog ‘NSNSIP-4b7280c8-4b7280cc-1-11-1366057139-11176-1366068315’ Method: ACK
Really destroying SIP dialog ‘[email protected]’ Method: OPTIONS
Reliably Transmitting (NAT) to 72.31.114.162:5060:
OPTIONS sip:72.31.114.162 SIP/2.0
Via: SIP/2.0/UDP 172.19.55.2:5060;branch=z9hG4bK6f1bfe41;rport
Max-Forwards: 70
From: “Unknown” sip:[email protected];tag=as215a210b
To: sip:72.31.114.162
Contact: sip:[email protected]:5060
Call-ID: [email protected]:5060
CSeq: 102 OPTIONS
User-Agent: FPBX-2.10.1(10.12.0)
Date: Mon, 15 Apr 2013 20:19:34 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Length: 0


<— SIP read from UDP:72.31.114.162:5060 —>
SIP/2.0 200 OK
Via: SIP/2.0/UDP 172.19.55.2:5060;received=71.43.192.30;branch=z9hG4bK6f1bfe41;rport=5060
From: sip:[email protected];tag=as215a210b
To: sip:72.31.114.162;tag=snl_0107691798
Call-ID: [email protected]:5060
CSeq: 102 OPTIONS
Contact: sip:72.31.114.162:5060;maddr=72.31.114.162;transport=udp
Supported: sip-stun
Content-Length: 0

<------------->
— (9 headers 0 lines) —
Really destroying SIP dialog ‘[email protected]:5060’ Method: OPTIONS
localhost*CLI> sip set debug off
SIP Debugging Disabled

Thanks in advance!!!

Try putting context=from-trunk in your trunk settings.

You know what fixed it? I was reading another thread and someone suggested to clear the “CallerID Number” field on my inbound route. And it worked. Thanks all!!!

Can anyone explain what that field does?

so if you only want to allow calls from your cell phone, then put your cell phone number in the caller id field

Thank you sir.