1

This is my situation:

Router A: IP 192.168.1.1 Mask 192.168.1.0/24 - Connected to the internet.

Server: - Interface eth0: inet addr:10.1.1.125 Mask:255.255.255.0 (connected to router B) - Interface ra0: inet addr:192.168.1.125 Mask:255.255.255.0 (connected to router A)

Router B: IP 10.1.1.254 Mask 10.1.1.0/24 - Connected to Server's eth0

Computer: connected to Router B via WiFi connection.

I configured a static route on Router B that use as default gateway 192.168.1.125 and i can ping that ip from computer.

The problem is: how i can connect to the internet ? In other words, traffic coming from Server eth0 should use ra0 as gateway.

Any suggestion ?

Thank you

1
  • If R-A is a consumer broadband router, it likely has a switch on the back .. any reason you don't connect R-B directly to R-A? – tomjedrz Dec 24 '09 at 16:59
0

You need to set up ip forwarding on your server. I recommend shorewall, but any of those tools would work. Or manually.

manual: http://www.ducea.com/2006/08/01/how-to-enable-ip-forwarding-in-linux/ shorewall: http://www.debianhelp.co.uk/shorewall.htm

You didn't specify your distro, so I'm assuming debian-y. Googleing "enable ip forwarding" and your distro would help.

And you'll want to change your router B to use 10.1.1.125 as the default gateway. Your server would have 192.168.1.125 as its default gateway and would know to forward traffic from your router B through to router A.

0

Why is the server dual homed? Why not connect it like this?

  Internet
    |
    |
    |
   WP
  -----
 |ARTR |
  -----
    LP
    |
    |
    |
   WP
  -----
 |BRTR | LP---Server
  -----



          PC – WIFI to BRTR


 WP = WAN Port
 LP = LAN Port
0

do you have a route in the A router that is pointing traffic bound for the 10.1.1.0/24 network to 192.168.1.125 ? I suspect that what is happening is that the return traffic does not know how to get back to the B router.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy