[SR-Users] Dispatcher alg:7 not working accordingly

SamyGo govoiper at gmail.com
Sun Jun 3 15:41:40 CEST 2012


Hello,

I'm having trouble using algorithm 7 in dispatcher module. Here is my
kamailio version. The problem is that despite multiple dispatcher entries
corresponding to one set all calls go only to only one destination.


[root at control1 ~]# kamailio -V
version: kamailio 3.2.3 (x86_64/linux) 59f87e
flags: STATS: Off, USE_IPV6, USE_TCP, USE_TLS, TLS_HOOKS, USE_RAW_SOCKS,
DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC,
DBG_QM_MALLOC, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE,
USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16,
MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 4MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 59f87e
compiled on 18:04:08 Apr 19 2012 with gcc 4.1.2
[root at control1 ~]#

Here is the dipacther module params.



# ------- Load-balancer params ------
modparam("dispatcher", "db_url", DBURL)
modparam("dispatcher", "table_name", "dispatcher")
modparam("dispatcher", "setid_col", "setid")
modparam("dispatcher", "destination_col", "destination")
modparam("dispatcher", "force_dst", 1)
modparam("dispatcher", "flags", 3)
modparam("dispatcher", "dst_avp", "$avp(i:271)")
modparam("dispatcher", "cnt_avp", "$avp(i:273)")
modparam("dispatcher", "ds_ping_from", "sip:proxy at 109.XXX.2XX.XX")
modparam("dispatcher", "ds_ping_interval",15)
modparam("dispatcher", "ds_probing_mode", 1)
modparam("dispatcher", "ds_ping_reply_codes",
"class=2;code=403;code=404;code=484;class=3")
modparam("dispatcher", "hash_pvar", "$avp(i:274)")
modparam("dispatcher", "ds_hash_size", 9)
modparam("dispatcher", "ds_hash_initexpire", 60)



Below is the function call based on avp(i:274)



avp_db_query("select uid from uid_did_map where accountcode =
'$fU'","$avp(i:274)");
xlog("L_INFO","$rm from $fu (IP:$si:$sp) ---------
UID:'$avp(i:274)-----------'\n");
        ds_load_update();
        if(!ds_select_dst("1","7")) {
                        sl_send_reply("500", "No destination available");
                        xlog("route[MAIN] : $rm : No destinations available
for $rd");
                        exit;
        }


I'm getting two different values for avp(i:274) {26,29} but the destination
are not hashed on its base.

Please help.

Regards,
Sammy G.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20120603/fdb6fc72/attachment.htm>


More information about the sr-users mailing list