I'm trying to implement failover using the load_contacts/next_contacts from the lcr module. The problem I have is the INVITE message is sent simultaneously to both contact's instead of trying the first and then the second. I keep getting 'load_contacts(): DEBUG: Nothing to do - all same q!' when I've set them up with separate q values??
Anyone else have issues with this? Did I set up the data incorrectly or possibly something in the config?
Thanks in advance for any help or advice Shannon
debug: 0(20640) rewrite_uri: Rewriting Request-URI with ' sip:3125551234@xx.xx.xx.144:5060' 0(20640) xl_get_spec_value: error - null sp->itf 0(20640) Lookup done 0(20640) load_contacts(): DEBUG: Nothing to do - all same q! 0(20640) Contacts loaded sip:3125551234@xx.xx.xx.144:5060 0(20640) next_contacts(): DEBUG: No AVPs -- we are done! 0(20640) Next Contacts loaded sip:3125551234@xx.xx.xx.144:5060
config snip: if(!lookup("location")) { sl_send_reply("404", "Not Found"); xlog("L_ERROR","Unkonwn location sending 404\n"); return; } else { xlog("L_INFO"," Lookup done \n"); } if(!load_contacts()){ sl_send_reply("500", "Server Internal Error - Cannot load translations"); xlog("L_ERROR"," Unable to load contacts <$ru> \n"); exit; } else { xlog("L_INFO"," Contacts loaded <$ru>\n"); } if(next_contacts()) { xlog("L_INFO"," Next Contacts loaded <$ru>\n"); t_on_failure("10"); } else { xlog("L_ERROR"," Unable to load next_contacts <$ru> \n"); exit; }
mysql location table: +------------+--------+-------------------------------------+----------+------+---------------------+------+-----------------+------+---------------------+-------+------------+--------+---------+ | username | domain | contact | received | path | expires | q | callid | cseq | last_modified | flags | user_agent | socket | methods | +------------+--------+-------------------------------------+----------+------+---------------------+------+-----------------+------+---------------------+-------+------------+--------+---------+ | 3125551234 | | sip:3125551234@xx.xx.xx.180:5060 | NULL | NULL | 2020-05-28 21:32:15 | 0.40 | Default-Call-ID | 42 | 2007-07-29 11:35:02 | 128 | | NULL | NULL | | 3125551234 | | sip:3125551234@xx.xx.xx.144:5060 | NULL | NULL | 2020-05-28 21:32:15 | 0.30 | Default-Call-ID | 42 | 2007-08-17 09:36:00 | 128 | | NULL | NULL | +------------+--------+-------------------------------------+----------+------+---------------------+------+-----------------+------+---------------------+-------+------------+--------+---------+