[SR-Users] ACK sent to wrong socket IP in mhomed scenario

Daniel-Constantin Mierla miconda at gmail.com
Thu Dec 12 15:25:02 CET 2013


Hello,

On 12/12/13 13:57, Ronald Voermans wrote:
> Dear list,
>
> I'm having an issue with our Kamailio setup.
>
>   I've installed two Kamailio servers with Corosync/Pacemaker. Kamailio1 has ip 10.254.254.5, Kamailio2 has ip 10.254.254.23. The VIP is 10.254.254.1. All is working well; clients can sent request to the VIP, and all traffic is sent via 10.254.254.1, and not the real ipI've configured the listen addressess:
>
> mhomed = no
> listen = udp:10.254.254.1:5060
> listen = udp:10.254.254.23:5060
>
> I'm now trying to configure the server as a multihomed one. Both Kamailio have two NIC's. Kamailio1 also has ip X1, Kamailio2 has ip X2. The VIP is Y. Configuration is done as:
>
> mhomed = yes
> listen = udp:10.254.254.1:5060
> listen = udp:10.254.254.23:5060
> listen = udp:Y:5060
> listen = udp:X1:5060
>
> When a UA sends an INVITE to for example 10.254.254.1, all responses (back) to UA are being sent with source address 10.254.254.1 (VIP), except for the ACK (and BYE). The ACK is sent via the real ip 10.254.254.23. I can resolve this by issuing a force_send_socket before t_relay in the config; but since it's multihomed, I have to build a lot of checks to find out the outgoing socket. Besides that, I want it to be possible to use both the real IP and the VIP as IP-address for the UA (for testing purposes). This won't work with force_send_socket.
>
> Does anyone from the list know how I can solve this?
force send socket is done only when there is a double record-routing 
situation. In this case no socket is forced and mhomed=yes gives the 
decision to the kernel routing table to select the socket, which I guess 
will find first 10.254.254.23 as having a route to where ACK or BYE has 
to be sent.

You can try to force the socket using the uri from the top Route header.

Might be good to enhance rr to do force socket even for one Route 
header, eventually controlled via a modparam .

Cheers,
Daniel

-- 
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda




More information about the sr-users mailing list