Hello Asterisk List,
My company is running a bunch of Asterisk servers behind a Kamailio  
(openSER) SIP proxy gateway.  Calls come in from our PTSN to VOIP  
service to Kamailio, which then randomly chooses an Asterisk server to  
handle the call.  All Asterisk servers are 1.6.0.9, but the issue I'm  
about to describe exists in 1.6.1.5-rc1 as well.

Ultimately what I want to do is cap each Asterisk server at a maximum  
number of simultaneous calls.  If the maximum number is hit, I want  
the call to get sent back to Kamailio which would then randomly send  
the call to another Asterisk server.

The easiest way to accomplish this seems to be in the asterisk.conf  
file.  In asterisk.conf is this line:
maxcalls=100 ; Maximum amount of calls allowed

This is great, and asterisk will deny calls once it hits this max  
number.  OK, here's where I get stuck.  Once that max is reached,  
Asterisk will send a "480 Temporarily Unavailable", which is great,  
and a "BYE" which is not great, as that gets passed along to the PTSN  
and hangs up the call.  Kamailio properly sends the call to another  
Asterisk server, but the call no longer exists because of the BYE and  
the call eventually times out on the new Asterisk server.

Is this BYE a bug in the way Asterisk handles SIP, or is this normal  
SIP behavior and I should find another way to gracefully deny the call  
back to Kamailio?

Thanks list,
Chris


_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2009 - October 13 - 15 Phoenix, Arizona
Register Now: http://www.astricon.net

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

Reply via email to