[OpenSIPS-Users] Dispatcher user specific route question - 2.1

Vlad Paiu vladpaiu at opensips.org
Thu Mar 19 17:41:09 CET 2015


Hello,

It will do fail-over.

Best Regards,

Vlad Paiu
OpenSIPS Developer
http://www.opensips-solutions.com

On 19.03.2015 18:39, Satish Patel wrote:
> Thanks Vlad,
>
> Superb! so it will do round-robin? or fail-over?
>
> On Thu, Mar 19, 2015 at 12:30 PM, Vlad Paiu <vladpaiu at opensips.org 
> <mailto:vladpaiu at opensips.org>> wrote:
>
>     Hello,
>
>     If you want to do dispatching between multiple setids,
>     ds_select_dst() allows that. See the docs at [1] , you can provide
>     a comma separated list of setids - so your $avp(zone) can contain
>     '1,2' and OpenSIPS will try to first send to the servers in setid
>     1, and then, if those fail, to the servers in setid 2.
>
>     [1]
>     http://www.opensips.org/html/docs/modules/1.11.x/dispatcher#id294368
>
>     Best Regards,
>
>     Vlad Paiu
>     OpenSIPS Developer
>     http://www.opensips-solutions.com  
>
>     On 19.03.2015 06:17, Satish Patel wrote:
>>     I have add extra "zone" column in subscriber table,
>>
>>     +--------------+---------+
>>     | username |  zone |
>>     +--------------+---------+
>>     |    1001     |    1    |
>>     |    1002     |    2    |
>>     +--------------+---------+
>>
>>
>>     In dispatcher table I have following two Freeswitch in two groups.
>>
>>     +-------+-----------------------------+--------------------+
>>     | setid | destination              | description    |
>>     +-------+------------------------------+-------------------+
>>     |     1 | sip:fs1.example.com <http://fs1.example.com> |
>>     Freeswitch-1 |
>>     |     2 | sip:fs2.example.com <http://fs2.example.com> |
>>     Freeswitch-2 |
>>     +-------+------------------------------+-------------------+
>>
>>
>>     in opensips.cfg script i am query subscriber table base on
>>     incoming username and storing zone in avp(zone) variable, and
>>     calling same variable in following code
>>
>>     if ( !ds_select_dst("$avp(zone)", "4", "FM10"))
>>
>>     Question: now either user belongs to zone 1 or 2, so it is *NOT*
>>     going to do load-balancing between two. But if I want to allow
>>     some user to do load-balancing then how it will be possible in
>>     above scenario?
>>
>>     Can i set "setid" on fly so i can pass request along with user
>>     request and set same group for both switch and user call
>>     load-balance on both switch?
>>
>>     Any other idea?
>>
>>
>>     _______________________________________________
>>     Users mailing list
>>     Users at lists.opensips.org  <mailto:Users at lists.opensips.org>
>>     http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
>     _______________________________________________
>     Users mailing list
>     Users at lists.opensips.org <mailto:Users at lists.opensips.org>
>     http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20150319/09dce118/attachment-0001.htm>


More information about the Users mailing list