Hi,
I have a RHEL 4 machine with 2.6.9-42.ELsmp kernel and connected with two ISPs. The default GW is Primary ISP it took automatically.
Here I created ip rule for Secondary ISP
added entry--> /etc/iproute2/rt_tables
100 SECO
ip rule add from 192.168.1.48/28 table SECO
ip route add default via x.x.x.x dev eth1 table SECO
ip rule show
------------------
0: from all lookup local
32765: from 192.168.1.48/28 lookup SECO
32766: from all lookup main
32767: from all lookup default
IP route show table SECO
--------------------------
----
default via x.x.x.x dev eth1
No firewall entries
[root@Linux~]# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Main Route table
-----------------------
[root@Linux~]# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 eth2
192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
x.x.x.x 0.0.0.0 255.255.255.0 U 0 0 0 eth1
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth2
127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo
0.0.0.0 y.y.y.y 0.0.0.0 UG 0 0 0 eth2
The above routing configuration present what I have.
which all come under main default route they can able to browse, which all comes under SECO table they were not able to ping GW itself.
Then I added one entry in firewall
iptables -t nat -A POSTROUTING -o eth1 -s 192.168.1.48/28 -j MASQUERADE
after adding above entry I can able to ping the GW but not browsing or any other out side IP.
From RHEL 4 machine I can able to access out side IP through that particular Interface.
Then I try to change my Main table default route to Secondary ISP then also I am no able to go out from client machines. From the server I can able to browse and I can able to ping out side IP with out any problem with all Interfaces.
This is the problem I am facing past one week. I tried all the ways what I know.
Please some one help me to solve this issue.
Thanks,
Expertblr
Start Free Trial