[OpenSIPS-Users] ACK not Relayed to correct destination on RE-INVITE

Andrew Pogrebennyk andrew.pogrebennyk at portaone.com
Wed May 4 18:13:59 CEST 2011


Hi Ash,
I don't see the re-INVITE in your trace but I see that ACK after 200 OK 
from Yealink is not routed properly. I think your Cisco 877 has some 
sort of SIP ALG enabled:

Note 200 OK message from FreeSwitch contains:
Record-Route: <sip:1.1.108.70;lr;ftag=1063201394;did=212.ef2d2d26>
Contact: <sip:xxxx7772 at 1.1.108.68:5060;transport=udp>

After that Yealink sends an ACK:
ACK sip:xxxx7772 at 2.2.239.241:1037;transport=udp SIP/2.0
Route: <sip:1.1.108.70;lr;ftag=1063201394;did=212.ef2d2d26>

Route header is correct, but Request-URI is wrong: it must contain 
remote target address from the Contact header: ACK 
sip:xxxx7772 at 1.1.108.68:5060;transport=udp

I think that if you collected the SIP trace from Yealink you would have 
found that router put its own IP address in Contact of 200 OK, hence it 
put router's IP into Request-URI.

The very first INVITE message from the Yealink is not quite right too: 
source ip:port is 2.2.239.241:1034 but Contact and Via contains 
2.2.239.241:1029. This might be caused but STUN not working properly, 
but since the problem occurs in both ways and with different UAs, Cisco 
877 is likely modifying the SIP headers.

On 29.04.2011 08:28, Ash wrote:
> Hi there,
>
> I have been trying for the last week to configure the load balancing in
> OpenSIPS.  I am trying to configure a load balancer as per the wiki on
> the Freeswitch page -
> http://wiki.freeswitch.org/wiki/Enterprise_deployment_OpenSIPS, I have
> also tried the sample on the OpenSIPS site and I am getting the same
> results.
>
> I am attempting to have all my registrations and Invites proxied to the
> the Freeswitch server which will do the call processing.  My phone is
> told to point to the SIP Domain voip2.siptest.net.au
> <http://voip2.siptest.net.au> which resolves to OpenSIPS.
>
>
> This is a quick layout of the path:
>
>     Yealink T20 - VOIP Phone - 10.2.0.2 (Private IP)
>     | (NAT)
>     Cisco 877 DSL Router (2.2.239.241) (Public IP)
>     |
>     INTERNET
>     |
>     OpenSIPS (1.1.108.70) (Public IP)
>     |
>     FreeSWITCH (1.1.108.68) (Public IP)
>     |
>     External VOIP Provider
>
>     (Assume 2.2.239.X and 1.1.108.X are public ranges)
>
>
> I register to the OpenSIPS load balancer using domains in this test case
> I am using 613xxxx2002 at voip2.siptest.net.au
> <mailto:613xxxx2002 at voip2.siptest.net.au> where voip2.siptest.net.au
> <http://voip2.siptest.net.au> is pointed to 1.1.108.70.  The
> registration appears normal on both the OpenSIPS and Freeswitch.  The
> destination I am calling is via another SIP provider which is routed by
> Freeswitch on the external profile.
>
> The problem I am seeing is that it looks like when a RE-INVITE happens
> the ACK gets sent back to 2.2.239.241 instead of being relayed to
> 1.1.108.70,  I can see the ACK from 2.2.239.241 but OpenSIPS then
> replies and sends the ACK message to 2.2.239.241 where it should be
> seeing that it needs to send it to 1.1.108.68.  Freeswitch will then
> keep sending 200 OK to OpenSIPS and then hang the call up after 30
> seconds as there has been no ACK received.  If there is no RE-Invite
> then the calls seems to work fine.  It only seems to be when a RE-Invite
> is sent by the Phone.  (I have tried a Siemens Gigaset and get the same
> issue). If I register the phone directly to Freeswitch I don't seem to
> have these issues.
>
> I have seen this issue mentioned on mailing lists in the past and I have
> tried the suggestions but none seem to work for me.
>
> I have provided the following which may assist:
>
> opensips.cfg
> http://pastebin.com/hG2GUHWV
>
> SIP Trace
> http://pastebin.com/8fahFPj3
>
> OpenSIPS debug
> http://pastebin.com/T9ULEeXt
>
>
> Hopefully someone out there might have some ideas.  Any advice would be
> appreciated.
>
> Cheers,
>
> Ash.

-- 
Sincerely,
Andrew Pogrebennyk



More information about the Users mailing list