Andrew Pogrebennyk
2014-09-12 13:42:29 UTC
Hi,
let's say I'm running two proxies/registrars that need to access Shared
location DB in db_mode=1 (all changes to usrloc are immediately
reflected in database too). I have observed that if the UAC re-registers
before the previous registration's expiry and the new REGISTER reaches
the other proxy than the one that processed the registration originally,
this new proxy is going to insert the second record for the same
username into location table instead of updating the existing registration.
I assume the problem is the ruid calculation, because proxy2 generated a
different ruid than proxy1 since internal state of the two nodes is not
shared. I have two questions: 1) is that assumption correct? 2) is there
any way to synchronize the "ruid" of the two nodes in usrloc module,
similar to the "secret" parameter in the auth module, or a better
solution? I prefer the load-balancer to select random proxy and not do a
hash based on From URI.
I don't have the trace of the two registrations at the moment, but could
get one next week. The issue popped up when running some sipp tests, but
it's also possible that some cheap SIP endpoint would register well
before the expiration time, creating duplicate registration. So if
someone dials its number it's going to receive multiple incoming calls.
Here are the module parameters I am using, all quite ordinary:
modparam("usrloc", "use_domain", USE_DOMAIN)
modparam("usrloc", "db_mode", 1)
modparam("usrloc", "db_url", CENTRAL_URL)
modparam("usrloc", "db_check_update", 0)
modparam("usrloc", "nat_bflag", FLB_NATB)
modparam("registrar", "default_expires", 3600)
modparam("registrar", "min_expires", 60)
modparam("registrar", "max_expires", 43200)
modparam("registrar", "method_filtering", 0)
modparam("registrar", "append_branches", 1)
modparam("registrar", "max_contacts", 5)
modparam("registrar", "received_avp", "$avp(s:received)")
modparam("registrar", "use_path", 1)
modparam("registrar", "path_mode", 0)
modparam("registrar", "path_use_received", 1)
modparam("registrar", "gruu_enabled", 0)
Any ideas?
Thanks in advance.
Andrew
let's say I'm running two proxies/registrars that need to access Shared
location DB in db_mode=1 (all changes to usrloc are immediately
reflected in database too). I have observed that if the UAC re-registers
before the previous registration's expiry and the new REGISTER reaches
the other proxy than the one that processed the registration originally,
this new proxy is going to insert the second record for the same
username into location table instead of updating the existing registration.
I assume the problem is the ruid calculation, because proxy2 generated a
different ruid than proxy1 since internal state of the two nodes is not
shared. I have two questions: 1) is that assumption correct? 2) is there
any way to synchronize the "ruid" of the two nodes in usrloc module,
similar to the "secret" parameter in the auth module, or a better
solution? I prefer the load-balancer to select random proxy and not do a
hash based on From URI.
I don't have the trace of the two registrations at the moment, but could
get one next week. The issue popped up when running some sipp tests, but
it's also possible that some cheap SIP endpoint would register well
before the expiration time, creating duplicate registration. So if
someone dials its number it's going to receive multiple incoming calls.
Here are the module parameters I am using, all quite ordinary:
modparam("usrloc", "use_domain", USE_DOMAIN)
modparam("usrloc", "db_mode", 1)
modparam("usrloc", "db_url", CENTRAL_URL)
modparam("usrloc", "db_check_update", 0)
modparam("usrloc", "nat_bflag", FLB_NATB)
modparam("registrar", "default_expires", 3600)
modparam("registrar", "min_expires", 60)
modparam("registrar", "max_expires", 43200)
modparam("registrar", "method_filtering", 0)
modparam("registrar", "append_branches", 1)
modparam("registrar", "max_contacts", 5)
modparam("registrar", "received_avp", "$avp(s:received)")
modparam("registrar", "use_path", 1)
modparam("registrar", "path_mode", 0)
modparam("registrar", "path_use_received", 1)
modparam("registrar", "gruu_enabled", 0)
Any ideas?
Thanks in advance.
Andrew