Multiple rules with the same prefix and with the stopper flag are added. All the rules have the same priority in the target table.
When routing calls to this prefix (load_gw + next_gw), the LCR module does not load balance the calls, it always sends to the same GW.
Scenario is the following, the LCR rules have one default GW which is reachable via an empty rule. However, a certain prefix must not be sent there, so a rule with the stopper flag is added pointing to another GW. This works fine and the default GW is never attempted.
However, for load balance purposes, it is necessary to send calls to this prefix to 2 different GWs. So another rule with the same prefix is added with the stopper flag set too. The target table was updated accordingly and has the same priority.
When we have all this setup, by calling "next_gw()" we always get the same GW (which is random depending on the DB situation I think). The other(s) GW is never attempted.
This does not allow to load balance 2 GWs for rules with the stopper flag.
Given the stopper flag should prevent selecting shorter prefixes, it should not restrict the routing for rules with the same prefix (same length). Having this, the load balance of stopper rules would be possible.
Apparently, there is no workaround, expect by not using the stopper flag, however then there is a risk of sending calls to GWs with shorter prefix length which is not desired.
kamailio -v
kamailio -v
version: kamailio 5.2.2 (x86_64/linux) 67f967
flags: STATS: Off, USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, 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_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 67f967
compiled on 11:40:41 Mar 11 2019 with gcc 4.8.5
uname -a
Linux uat1-sbc-0002 3.10.0-1062.1.2.el7.x86_64 #1 SMP Mon Sep 30 14:19:46 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.