[Freeswitch-users] sofia gateways and linux multipath routing

François Delawarde fdelawarde at wirelessmundi.com
Tue Oct 13 03:09:45 PDT 2009


Hello all,

I'm interested in using mod_sofia with multiple Internet connections
(configured as a unique load-balancing route using multipath).

One solution would be to define a different profile for each connection,
but it would be more practical having a unique external profile that
would automatically handle everything (detecting multiple public IPs and
selecting the right one for a call, being able to select the router for
gateway registration...).

Routing table:
192.168.10.0/24 dev eth0  proto kernel  scope link  src 192.168.10.1
192.168.1.0/24 dev eth1  proto kernel  scope link  src 192.168.1.2
192.168.2.0/24 dev eth2  proto kernel  scope link  src 192.168.2.2
default  proto static
	nexthop via 192.168.1.1  dev eth1 weight 1
	nexthop via 192.168.2.1  dev eth2 weight 1

Both default routers (192.168.1.1 and 192.168.2.1) would have a distinct
public IP.

Several questions cross my mind:
- Can a unique sofia profile be bound to multiple IPs (not 0.0.0.0)?

- How would FS behave with a unique external profile in that situation?
   * Would FS reply to an incoming call using the same router it came
from forcing packet source address?
   * Would FS stick to a unique router for all flows of an outgoing call
(SIP, RTP, UDPTL)?
   * Can I force a gateway to use a given router (for calls,
registration, ...)?
   * Would the NAT system (using stun or auto-nat) work in that
situation, or does it assume only one default router (and a unique
public IP) exists per profile?

- Knowing the above, would it be necessary to use a different profile
for each router/interface, and define the same gateway in each of these?

- Tricky question: What if multiple routers are on the same
network/interface (192.168.1.1, 192.168.1.2, ...)?


Thanks in advance,
François.





More information about the FreeSWITCH-users mailing list