[asterisk-ha-clustering] Load sharing between two asterisk servers

Julian J. M. julianjm at gmail.com
Wed Jan 9 08:58:50 CST 2008


On Jan 9, 2008 2:07 PM, Allan Cassaro <allan.cassaro at gmail.com> wrote:
> In this scenario, 2 servers working in active/Active way, how can I
> pickup calls?
> It's only possible to pickup calls on server that my phone is
> registered, right? DUNDi can help with this?
> I can create a extension to pickup and trasnfer calls between IAX channels?

You can make use of regcontext (see sample sip.conf). Asterisk will
dynamically create a priority 1 NoOp extension for registered peers.
Example:

sip.conf
======
regcontext=extensions

extensions.conf
===========
[extensions]
exten => _3XXX,2,Dial(SIP/${EXTEN})  ; Note, priority 2
include => dundi-lookup

[dundi-lookup]
switch => DUNDI/extensions


If an extension is registered locally (e.g. 3000), there'll be a
"exten => 3000,1,NoOp" in context [extensions]. It will continue on
priority 2, thus ringing SIP/3000.
If it's not registered, it will perform a DUNDi lookup to get the real
location of the dialed extension, if any.

Also, to simplify things, if you only have 2 servers, instead of dundi
you can use the other server's dialplan through an IAX2 switch:
switch => IAX2/user:pass at serverB/extensions

Julián J. Menéndez

-- 
http://www.julianmenendez.es



More information about the asterisk-ha-clustering mailing list