<div dir="ltr">Thank you. I tested using manual and so far seems to be working fine.</div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 30, 2016 at 7:04 PM, Bogdan-Andrei Iancu <span dir="ltr"><<a href="mailto:bogdan@opensips.org" target="_blank">bogdan@opensips.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div text="#000000" bgcolor="#FFFFFF">
<tt>Hello Nash,<br>
<br>
This is a limitation of how mhomed works - basically opensips asks
the OS to provide a suitable source interface to reach a certain
destination. But OS will consider all the network interface, not
only the ones configured in OpenSIPS. So, the OS may select and
return an interface not used by OpenSIPS.<br>
<br>
What you can do:<br>
1) make 1.1.1.1 default interface, to favor it in the OS selection<br>
2) disable mhomed and use manual selection of the interface via
force_send_socket()[1] or $fs[2]<br>
<br>
For each GW, dr_gateway, you can store in attributes string some
info about the interface to be used to reach that GW.<br>
<br>
[1]
<a href="http://www.opensips.org/Documentation/Script-CoreFunctions-2-2#toc16" target="_blank">http://www.opensips.org/Documentation/Script-CoreFunctions-2-2#toc16</a><br>
[2] <a href="http://www.opensips.org/Documentation/Script-CoreVar-2-2#toc43" target="_blank">http://www.opensips.org/Documentation/Script-CoreVar-2-2#toc43</a><br>
<br>
Regards,<br>
</tt>
<pre cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a href="http://www.opensips-solutions.com" target="_blank">http://www.opensips-solutions.com</a></pre><div><div class="h5">
<div>On 30.05.2016 11:33, John Nash wrote:<br>
</div>
</div></div><blockquote type="cite"><div><div class="h5">
<div dir="ltr">On my linux box we have multiple public IP
addressess
<div>1.1.1.1</div>
<div>2.2.2.2</div>
<div>3.3.3.3</div>
<div><br>
</div>
<div>I am listening on two of them as </div>
<div>udp:<a href="http://1.1.1.1:5060" target="_blank">1.1.1.1:5060</a></div>
<div>udp:<a href="http://2.2.2.2:5060" target="_blank">2.2.2.2:5060</a> </div>
<div><br>
</div>
<div>I have mhomed=1 in my config. I am also using drouting
module. What I expect is when an Invite comes to <a href="http://1.1.1.1:5060" target="_blank">1.1.1.1:5060</a>
. drouting should send outgoing invite using 1.1.1.1 as source
IP but it tries to send using 3.3.3.3 (Which is default
interface)</div>
<div><br>
</div>
<div>Is this the expected behavior of mhomed ?..should I
manually try to control this? </div>
</div>
<br>
<fieldset></fieldset>
<br>
</div></div><pre>_______________________________________________
Users mailing list
<a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
<br>
</div>
</blockquote></div><br></div>