[ opensips-Bugs-2956739 ] SRV lookup not correct

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ opensips-Bugs-2956739 ] SRV lookup not correct

SourceForge.net
Bugs item #2956739, was opened at 2010-02-22 22:38
Message generated for change (Comment added) made by bogdan_iancu
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=1086410&aid=2956739&group_id=232389

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: core
Group: 1.6.x
>Status: Closed
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Byron Clark (byron_clark)
Assigned to: Bogdan-Andrei Iancu (bogdan_iancu)
Summary: SRV lookup not correct

Initial Comment:
When using an SRV record to relay to a destination, OpenSIPS will repeatedly attempt to send the message to the second result in the lookup reply.

Here's an example (assume no response is received to the message):
- call t_relay() to relay to sip.example.com
- OpenSIPS performs SRV lookup for _sip._udp.sip.example.com
- DNS responds with sip1.example.com, sip2.example.com, sip3.example.com, sip4.example.com (equal priority)
- OpenSIPS performs A lookup for sip1.example.com
- OpenSIPS relays the message to sip1.example.com (including retransmits)
- OpenSIPS performs A lookulp for sip2.example.com
- OpenSIPS relays the message to sip2.example.com (including retransmits)

At this point, OpenSIPS should attempt to use sip3.example.com, but instead continues to lookup and then send the message to sip2.example.com until these errors show up in the log:
Feb 18 16:36:08 bgw1 opensips[1745]: ERROR:tm:add_uac: maximum number of branches exceeded
Feb 18 16:36:08 bgw1 opensips[1745]: ERROR:tm:t_forward_nonack: failure to add branches

----------------------------------------------------------------------

>Comment By: Bogdan-Andrei Iancu (bogdan_iancu)
Date: 2010-03-04 14:11

Message:
Hi Byron,

Thanks for the fix - indeed, it is correct. I applied the same fix to the
NAPTR iteration also. Both fixes are available o trunk, 1.6 and 1.5

Regards,
Bogdan

----------------------------------------------------------------------

Comment By: Byron Clark (byron_clark)
Date: 2010-02-24 17:33

Message:
Log attached.  DNS record is SRV
_sip._udp.wholesaleorigination.acc.globalipcom.com.

----------------------------------------------------------------------

Comment By: Bogdan-Andrei Iancu (bogdan_iancu)
Date: 2010-02-24 11:40

Message:
Hi,
Could you post the logs (debug=4) for such a scenarios ? it will be easier
for me to understand what is going on.

Also, if the DNS record is public, maybe we could let me know its name, so
that I can try for myself.

Regards,
Bogdan

----------------------------------------------------------------------

Comment By: Byron Clark (byron_clark)
Date: 2010-02-22 22:40

Message:
The attached patch (against the 1.6 branch) causes OpenSIPS to correctly
walk through all of the SRV responses instead of continuing to use the same
entry.

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=1086410&aid=2956739&group_id=232389

_______________________________________________
Devel mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel