second internet line

Make use of Another Online connection for SIP

Predicament: Asterisk is operating to a ship that will be worldwide web router to get a LAN and contains two online links. Presume the default option stays to the very first online relationship.


Target: to utilize the very first online relationship for most normal online traffic and also another online link for most VoIP targeted visitors. In case reinvites are disabled, then it’d be enough only to track the SIP peer-reviewed through the 2nd online relationship. When utilizing reinvites, then that is impossible, as you can’t ever know that server that the traffic is currently reinvited to.


It’s now not possible to utilize several speeches from the bindaddr parameter from sip.conf. To be certain, all VoIP site visitors will not utilize the next online relationship, make use of this workaround.


From the Subsequent instance, let us presume the next:

Lan community: 4 on eth0, the host, includes

i net inch: on eth1, host contains, gateway is

i net two: on eth2, host contains, gateway is

sip supplier:

asterisk is functioning as person asterisk


Inch. Make certain that you have an operating set using appropriate source-routing to your internet protocol address of their next online relationship.


 # Insert our default path IP route add default dev eth1

# Populate routing Dining Table for 2 Nd nic

IP route show table chief | grep -standard default | while read line; perform route add on lineup desk line2; performed # Add a default path to Dining Table for 2 Nd nic

IP route add default through dev eth2 Dining Table line2

# do proper resource routing for IP speech of the Second nic

IP rule add from dining table line2

  1. Insert a path for your SIP peer-reviewed (your supplier ) throughout the next nic, however at the primary routing table


Ip route includes by way of src dining table chief. 

  1. Establish proper firewalling:


  1. The trail all noticeable traffic During the 2nd nic:


Ip rule add mark 0x2 dining table line2

The huge trick here is located in tricking asterisk into enrolling using the internet protocol address of this 2nd nic.  Incorporating the path into the SIP peer-reviewed towards the primary dining table induces asterisk touse the 2 nd origin speech at the SIP packs on their own.  (It may be potential to complete something together with SIP nat the following. However, I am uncertain about this )  All noticeable targeted traffic is moving out throughout the 2nd nic, also when visitors are reinvited into additional servers.  As the asterisk enrollment in the supplier features the IP address of their two and nic, all incoming visitors is going to be transmitted into this nic too.


Internet site Sponsor

Hunt for: Hunt

Speedy Backlinks

Cellular VoIP

Organization VoIP answers

Hosted VoIP answers

Asterisk PBX downLoad

Opensource VOIP Software Program



Wholesale Voice