[SR-Users] default IP to forward TCP request

Klaus Darilion klaus.mailinglists at pernau.at
Wed Mar 7 16:58:34 CET 2012


http://www.kamailio.org/wiki/cookbooks/3.2.x/core#tcp_source_ipv4_tcp_source_ipv6

On 07.03.2012 16:40, Laurent Schweizer wrote:
> Hello all,
>
> I have a linux server with different IP.
>
> eth0 -> 10.2.2.4
>
> eth0:1 -> 10.2.2.5
>
> I have kamailio listening on IP:
>
> listen=udp:10.2.2.5:5060
>
> listen=tcp:10.2.2.5:5060
>
> and in the script I do :
>
> rewritehostport("10.2.2.10:5060;transport=tcp");
>
> if (!t_relay()) {
>
> sl_reply_error();
>
> }
>
> exit;
>
> the problem is that t_relay is not using the IP 10.2.2.5 to forward this
> SIP request but the eth0 IP ( 10.2.2.4)
>
> I see that they is a function force_send_socket , I need to use this
> function to set the correct IP used to forward the request ?
>
> As I’m using only one IP 10.2.2.5 for openser, why he cannot always use
> this ip as default Ip ?
>
> Best regards
>
> Laurent
>
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users



More information about the sr-users mailing list