[Asterisk-Users] Help with incoming SIP routing

2006-06-28 Thread Christopher Aloi
Hello -I currently have 10 DID's coming into one Asterisk server, I seem to be having some difficulty routing based on the DID dialed and am hoping someone on the list can assist me.Here's the relevant info:
Ingress SIP trunk:IP: 123.45.45.3456DID's XXX-XXX-XX00-XX10sip.conf:[general]useragent=Asteriskport=5060context=defaulttos=lowdelaydisallow=allallow=ulawallow=alaw
allow=gsmrtptimeout=300rtpholdtimeout=600// // My thought in this context is I will grab any incoming SIP call from the IP address of my SIP trunk and pass it to my sip-defaul-in context // // in extensions.conf
[sip-default-in]type=frienddefaultip=123.45.3456host=123.45.3456nat=noinsecure=verycontext=sip-default-incanreinvite=nodtmfmode=rfc2833// // My thought here is I will grab any incoming SIP call form the IP address of my SIP trunk that matches XXX-XXX-XX00 and pass it to my XXX-XXX-XX00 context in 
extensions.conf[00]type=frienddefaultip=69.67.248.51host=69.67.248.51fromuser=00nat=nocontext=00
insecure=veryAnd a look at extesions.conf:// // My thought is here I will route my incoming calls to a DID i haven't specifically routed to my default context (GoTo(XXX))[sip-default-in]exten = s,1,Answer()
exten = s,2,Playback(beep)exten = s,2,Ringingexten = s,3,Wait,1exten = s,4,GoTo(XXX)// // My thought here is I will handle my incoming calls to XXX-XXX-XX00 and pass it to a specific context, say a queue
[00]exten = _00,1,Answer()exten = _00,2,Playback(beep)exten = _00,3,GoTo(queue-test,s,1)What am I doing wrong??I can receive calls fine, but they aren't routing properlyI think I overlooked something.
Thanks list!!/Chris
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Help with incoming SIP routing

2006-06-28 Thread El Flynn

Christopher Aloi wrote:

Hello -

I currently have 10 DID's coming into one Asterisk server, I seem to be
having some difficulty routing based on the DID dialed and am hoping 
someone

on the list can assist me.


snip

Unless I'm misunderstanding you, how about trying this:

1. In your sip.conf:

[general]
useragent=Asterisk
port=5060
context=default
tos=lowdelay
disallow=all
allow=ulaw
allow=alaw
allow=gsm
rtptimeout=300
rtpholdtimeout=600

2. In your extensions.conf:

[default]
exten = s,1,Goto(${CALLERIDNUM},s,1)

[123456789]
exten = s,1,Answer()
exten = s,2,Playback(beep)
exten = s,3,GoTo(queue-test,s,1)


So if you get an incoming SIP call from 123456789, it enters the default 
context and is then routed to the 123456789 context.


Flynn


___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Help with incoming SIP routing

2006-06-28 Thread Christopher Aloi
Hello - Thanks for the suggestions, I actually learned since my post that the problem is related to the formation of the initial SIP invite sent from our Sonus gateway through our NexTone SBC. Using your idea regarding the variable I think i've found a work-around.
When the Sonus sends the inital invite the format is:INVITE sip:315579;npdi=[EMAIL PROTECTED] SIP/2.0It appears the Asterisk server is able to parse this message if I am only using one context, it appears to fail when I use multiple contexts to route my ingress calls.
From what I can tell Asterisk parses the invite and looks to send the call to s in the default context (domain 315579).Looking for s in default (domain 315579)If 's' doesn't exist in [315579] the call chokes.
If I create a variable based on the ingress 'domain' using:exten = s,1,Goto(${SIPDOMAIN},s,1)The call is sent to the correct context.I think it's a work-around, but it seems to do the trick.
 -- Executing Goto(SIP/15241-08198868, 315579|s|1) in new stack -- Goto (315579,s,1) -- Executing Answer(SIP/15241-08198868, ) in new stack
Notes on Digium:http://bugs.digium.com/view.php?id=7208nbn=24
On 6/28/06, El Flynn [EMAIL PROTECTED] wrote:
Christopher Aloi wrote: Hello - I currently have 10 DID's coming into one Asterisk server, I seem to be having some difficulty routing based on the DID dialed and am hoping someone
 on the list can assist me.snipUnless I'm misunderstanding you, how about trying this:1. In your sip.conf:[general]useragent=Asteriskport=5060context=default
tos=lowdelaydisallow=allallow=ulawallow=alawallow=gsmrtptimeout=300rtpholdtimeout=6002. In your extensions.conf:[default]exten = s,1,Goto(${CALLERIDNUM},s,1)[123456789]
exten = s,1,Answer()exten = s,2,Playback(beep)exten = s,3,GoTo(queue-test,s,1)So if you get an incoming SIP call from 123456789, it enters the defaultcontext and is then routed to the 123456789 context.
Flynn___--Bandwidth and Colocation provided by Easynews.com --Asterisk-Users mailing listTo UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users