hmaupin
asked on
IP Forwarding on CENTOS box.
I have an Asterisk installation on CentOS on a box with four ethernet cards (actually two dual port cards) eth0, eth1, eth2, eth3. I am currently having a problem with dropped calls and to reduce the finger pointing want to put the box directly on the providers circuit using a static IP address (I have several available from the provider).
Eth2 is currently facing the subnet with the phones. I would like to use eth3 to interface to the internet using the fixed IP from the provider as I do not have enough IP address for all the phones, and do not want to reprovision all of them. How do I set up IP forwarding to & from eth2 & eth3?
To rephrase, I would like eth2 to service the phone subnet, and eth3 to connect to the internet via a fixed IP, and for the asterisk traffic to and from phones (subnet) and trunks (internet) to be automagically routed to the correct place and the connections with the trunk maintained. Since the trunk can originate connections when inbound calls are received, I need to provide for that in the rules as well.
Thanks!
Eth2 is currently facing the subnet with the phones. I would like to use eth3 to interface to the internet using the fixed IP from the provider as I do not have enough IP address for all the phones, and do not want to reprovision all of them. How do I set up IP forwarding to & from eth2 & eth3?
To rephrase, I would like eth2 to service the phone subnet, and eth3 to connect to the internet via a fixed IP, and for the asterisk traffic to and from phones (subnet) and trunks (internet) to be automagically routed to the correct place and the connections with the trunk maintained. Since the trunk can originate connections when inbound calls are received, I need to provide for that in the rules as well.
Thanks!
ASKER
Great, thanks, will give this a go over the weekend and update you. Thanks!
ASKER
Apologies, did not have a chance, will have to wait for another opportunity to configure the box. FYI, Harold
ASKER
Well, this did not work, none of the trunk registered after making the changes, changing the network connections, and rebooting. Had to fall back to the status quo. Must be missing something basic.
Please can you post here the output of the Linux "route" command. Also confirm the IP addresses assigned to eth0 to eth3 using the Linux command "ifconfig" and post here the output of the Asterisk CLI command "sip show settings".
ASKER
The settings (as currently exist in production) are attached as a text file. Currently eth2 handles all the traffic to/from phones and to/from SIP. Eth3 is not connected at the moment, but connected it for test.
Thanks!
asterisk-settings.txt
Thanks!
asterisk-settings.txt
Did you change the default gateway when you connected eth3?
ASKER
Yes, but changed it back after things did not register. Still working on a window to try it again, thanks!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks, this is very helpful. Will be trying it this weekend if all goes well.
ASKER
Still trying to work out a window ...
You will also need to fix some settings in Asterisk as follows:
sip.conf > [general] > externip=<ip_address_of_et
sip.conf > [general] > localnet=<subnet_on_eth2>
sip.conf > [trunk_peer_definition] > canreinvite=no