Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need help for linux routing

Status
Not open for further replies.

skkoh

IS-IT--Management
Jul 7, 2002
14
MY
Hi,

I need help to route my branch pc to internet via HQ
firewall. How can i set routing for my branch and HQ linux router? I am new is routing.

any pls help, below is my current network diagram.

tks



internet<--->Firewall<-------->Suse10-hqrouter<--->Suse10-branch router



Internet
^
|
|
eth0 : Public Ip ( Dlink Firewall Nat router. )
eth1 : 192.168.22.1
^
|
|
HQ Lan Network: 192.168.22.0/24
^
|
|
eth1: 192.168.22.16 ( Suse10-hq Router )
eth0: 192.168.200.1 ( Ip forwarding enable )
^
| IP Network ( lease line )
|
eth0: 192.168.200.2 ( Suse10-branch Router )
eth1: 10.0.1.1 ( Ip forwarding enable )
^
|
|
Branch network : 10.0.1.0/24
 
try
route add 192.168.200.0 10.0.1.1
route add 192.168.22.0 192.168.200.1
route add default gw 192.168.22.1
 
Hi stanhubble

Thank for reply,

Where should i add this route to
in Suse10-hq Router or Suse10-branch Router?


tks
 
in the branch box.


QatQat

Life is what happens when you are making other plans.
 
Hi,

This does not work?

From HQ Dlink fire i have point route to
10.0.1.0 255.255.255. gw 192.168.22.16


Suse10-hq Router
eth1: 192.168.22.16
eth0: 192.168.200.1

Suse10-hq Router:~ # route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.200.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
192.168.22.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
10.0.1.0 192.168.200.2 255.255.255.0 UG 0 0 0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0
127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo
0.0.0.0 10.0.0.1 0.0.0.0 UG 0 0 0 eth1


Suse10-branch Router
eth0: 192.168.200.2
eth1: 10.0.1.1

Suse10-branch Router:~ # route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.200.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
192.168.22.0 192.168.200.1 255.255.255.0 UG 0 0 0 eth0
10.0.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
192.168.200.0 10.0.1.1 255.255.255.0 UG 0 0 0 eth1
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0
127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo


after changing i have the above routing table but i can
connect to internet via HQ DLink nat firewall.

I can't even ping from my Suse10-branch Router to Dlink
ip 192.168.22.1 and i can only to 192.168.22.16.

What i have miss to do on the routing table?

tks

 
you would add those routes on the "branch pc" that you mentioned in the original question.

it should work....
start at the branch pc and see how far you can ping...
ie start with 10.0.1.1
then ping 192.168.200.2
the ping 192.168.200.1 ...etc

this is assuming that you have the routers set to answer icmp requests.
 
Try a tracert too.



BocaBurger
<===========================||////////////////|0
The pen is mightier than the sword, but the sword hurts more!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top