SIP Inbound DID routing

skykingoh
Posts: 1012
Member Since:
2007-12-17

Hey - I can see the inbound SIP invites from my gateway, however they all get routed to the invalid station intercept.

I looked at th code and it looks right.

Inbound is very close. I have tried changing the context to from-trunk and from-pstn with no change. The box answers with a not in service message. I tried to follow the contexts in extensions.conf just to understand the meaning of the context but could not figure it out.

I have copied my trunk settings below,

[ext-did]
include => ext-did-custom
exten => fax,1,Goto(ext-fax,in_fax,1)
exten => s,1,Set(__FROM_DID=${EXTEN})
exten => s,n,GotoIf($[ "${CALLERID(name)}" != "" ] ?cidok)
exten => s,n,Set(CALLERID(name)=${CALLERID(num)})
exten => s,n(cidok),Noop(CallerID is ${CALLERID(all)})
exten => s,n,Goto(from-did-direct,200,1)
exten => 6312846580,1,Set(__FROM_DID=${EXTEN})
exten => 6312846580,n,GotoIf($[ "${CALLERID(name)}" != "" ] ?cidok)
exten => 6312846580,n,Set(CALLERID(name)=${CALLERID(num)})
exten => 6312846580,n(cidok),Noop(CallerID is ${CALLERID(all)})
exten => 6312846580,n,Goto(from-did-direct,203,1)

[6312846580@66.243.25.35]
type=friend
insecure=very
host=64.158.162.78
context=from-trunk

Debug trace:

Executing NoOp("SIP/64.158.177.99-08fd42a0", "Received incoming SIP connection from unknown peer to 6312846580") in new stack
-- Executing Set("SIP/64.158.177.99-08fd42a0", "DID=6312846580") in new stack
-- Executing Goto("SIP/64.158.177.99-08fd42a0", "s|1") in new stack
-- Goto (from-sip-external,s,1)
-- Executing GotoIf("SIP/64.158.177.99-08fd42a0", "0?from-trunk|6312846580|1") in new stack
-- Executing Set("SIP/64.158.177.99-08fd42a0", "TIMEOUT(absolute)=15") in new stack
-- Channel will hangup at 2008-03-07 04:01:54 UTC.
-- Executing Answer("SIP/64.158.177.99-08fd42a0", "") in new stack
-- Executing Wait("SIP/64.158.177.99-08fd42a0", "2") in new stack
-- Executing Playback("SIP/64.158.177.99-08fd42a0", "ss-noservice") in new stack
-- Playing 'ss-noservice' (language 'en')
-- Executing PlayTones("SIP/64.158.177.99-08fd42a0", "congestion") in new stack
-- Executing Congestion("SIP/64.158.177.99-08fd42a0", "5") in new stack

Scott



KodaK
Posts: 1692
Member Since:
2006-06-14
Have you set up a "catch

Have you set up a "catch all" inbound route with a destination?

If you want that particular DID to go somewhere, have you set up an inbound route for DID "6312846580"?

Also: "Received incoming SIP connection from unknown peer to 6312846580" indicates that it doesn't know who the sending party is, for troubleshooting you could turn on "Allow Anonymous Inbound SIP Calls?" in general settings.

--

I'm happy to try to help in these forums for free, but if you feel compelled, or if you desire one on one help, my Paypal address is: sakodak@gmail.com



skykingoh
Posts: 1012
Member Since:
2007-12-17
I do have a catchall acount

I also thought I had the inbound trunk set up correctly, it matches the trunk entry.

I will try the Anonymous check box.

Scott



KodaK
Posts: 1692
Member Since:
2006-06-14
Just to be clear, you don't

Just to be clear, you don't want to leave that checkbox on for production (well, unless you understand the implications, which you probably do.)

--

I'm happy to try to help in these forums for free, but if you feel compelled, or if you desire one on one help, my Paypal address is: sakodak@gmail.com



skykingoh
Posts: 1012
Member Since:
2007-12-17
That solved the problem

Thanks, my route is right I just need to authenticate the peer correctly now.



citapinc
Posts: 98
Member Since:
2007-10-13
What did you do?

Scott:

I'm having the same issue. I can dial out all day long but all incomming calls get the message "Not in Service at this time". I've done the same thing you have and still cannot get it to work.

You mentioned "authenticate the peer correctly", what does that mean and what did you do to make it work?

Thanks.



skykingoh
Posts: 1012
Member Since:
2007-12-17
If you check the anonymous

If you check the anonymous SIP connections box on the general settings page it will allow connections from any outside source to send a SIP invite.

Take a look at SIP call flows, you can send a SIP invite in the blind to a host. The preferred way to connect is via a back to back user agent (B2BUA) that uses the SIP register method to create a virtual session between the peers.

Much of this is abstract and not of much concern unless you want to get under the hood. If you post who your provider is chances are somebody has already gotten Trix to work with that provider and will help you.

Scott



citapinc
Posts: 98
Member Since:
2007-10-13
If you check the anonymous

Scott:

The only way to get my inbound to work is by checking the "Allow Anonymous Inbound SIP Calls?" which I don't like. I'm currently using Teliax as my provider and all they can say is "your Trixbox is answering the phone but we dont know why it's not getting routed to your IVR.". So at this point I'm lost.

Has ANYONE out there been sucessful in getting inbound calls from Teliax to work when your TrixBox is behind a firewall on a Dynamic IP DSL connection?

Doe ANYONE know how to get past this Anonymous SIP calls issue?

Thanks!



dariuss
Posts: 1
Member Since:
2008-03-16
Damn I'm having the same

Damn I'm having the same issue as you citapinc ... using a SIP provider for a SIP trunk, outbound is all good but can't receive incoming calls at all. I've even tried two different providers.



djsullie
Posts: 84
Member Since:
2008-02-16
Similar issue here. Except

Similar issue here. Except when I create a catch all (Any DID any CID) it works. But when I specify a DID on
an inbound trunks calls then fail. Have no idea as to why. Been messing with this for weeks. no luck anyone
have any suggestions below are some configs.

Bad call
-- Executing NoOp("SIP/303719xxxx-09c15278", "No DID or CID Match") in new stack
-- Executing Answer("SIP/303719xxxx-09c15278", "") in new stack
-- Executing Wait("SIP/303719xxxx-09c15278", "2") in new stack
-- Executing Playback("SIP/303719xxxx-09c15278", "ss-noservice") in new stack
-- Playing 'ss-noservice' (language 'en')
-- Executing SayAlpha("SIP/303719xxxx-09c15278", "") in new stack

exten => s,1,GotoIf($["${MOHCLASS}" = ""]?dial)
exten => s,2,SetMusicOnHold(${MOHCLASS})
exten => s,3(dial),AGI(dialparties.agi)
exten => s,4,NoOp(Returned from dialparties with no extensions to call and DIALSTATUS: ${DIALSTATUS})



skykingoh
Posts: 1012
Member Since:
2007-12-17
Can't help with that data.

Can't help with that data.

set your verbose to 0 and then start sip debug peer

Sounds like your inbound DID ANI does not match the route statement.

Here is an example from my extensions_addiotioanl.conf in the [ext-did] section. Just look do not edit this file it is generated by FreePBX, when problems creep up it is good to look at the dial plans FreePBX generates.

exten => 2165551212,n,Goto(from-did-direct,210,1)

Scott



danish
Posts: 4
Member Since:
2008-03-16
also the same problem but with cisco fxo or fxs

i have the same problem outgoing from trxibox 2.6.0 is working either to fxs or fxo
but incoming only rings at my soft phone behind trxibox but as soon as i pick the call up it got hanged up

anyone have any idea what might be missing.



djsullie
Posts: 84
Member Since:
2008-02-16
"Similar issue here. Except

"Similar issue here. Except when I create a catch all (Any DID any CID) it works. But when I specify a DID on
an inbound trunks calls then fail. "

I fianlly figured out what i was doing wrong. On my registration string I did not specify a DID at the end I was using :5060 added my did to the end and calls are now routing correctly. Not saying it will fix your problems but worth looking into

username:password@myvoip.com/DID

Dan



hasayed
Posts: 14
Member Since:
2007-09-27
similar problem here

and nothing works at all, not even allowing anonymous inbound calls nor the catch all any did/any cid inbound routing.



Billy2b
Posts: 6
Member Since:
2008-04-14
Inbound

By me, asterisk see the inbound call but doesn't redirect it....
I don't find what to do.....



gzpxyj
Posts: 14
Member Since:
2008-01-11
I have tried days to see

I have tried days to see what is wrong but still not quite figuring out yet. I thought to get IVR but it does not go to IVR at all. Seems the call never get into the trixbox. But the voip provider showed the calls are answered. And the report shows nothing if I call from outside. Dialing out is OK but not getting in. I updated some special incoming section with peer = xxx statement and find out that that statement causes some problem. The extra space at the end then ; for the comments showed the length of the string is one extra long, which basically added a space at the end. When I remove that space, the call transfered to the voice mail. I have to check if it is the trixbox voice mail or the isp's voice mail. Anyway, it is a nightmare to configure the box. What I want is to use the IVR, not answer directly. But I have not figured it out yet. Hopefully someone can point to the right solution. I am using trixbox ce and viatalk sip.



starlights
Posts: 2
Member Since:
2008-04-10
username:password@myvoip.com/DID

I had problem with routing the inbound, for differtent incoming trunks.

1 -Adding the DID in the registration string: -> username:password@myvoip.com/DID <--
DID is the same as the username.

2 - fill in the right inbound rout the DID. Leaving CLI and other parameters blank.
just fill in de extension or ivr.

It worked for me!

Many thanks to djsullie

Greetings Jerry



Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.