Networking Forums

Networking Forums > Computer Networking > Linux Networking > simple routing setup ...

Reply
Thread Tools Display Modes

simple routing setup ...

 
 
moritz@uplink-verein.ch
Guest
Posts: n/a

 
      09-17-2005, 07:06 PM
hi

all i want is to connect two networks:
172.17.0.0/16 and 172.18.0.0/16

i followed several how-tos and manuals for setting up my machine, but
something is odd and i don't figure out what.

so this are my steps:
ifconfig eth0 172.17.1.7 netmask 255.255.0.0 up
ifconfig eth1 172.18.0.1 netmask 255.255.0.0 up

ip route add net 172.17.0.0/16 dev eth0
ip route add net 172.18.0.0/16 dev eth1
ip route add default gw 172.17.0.1 dev eth0

i can now connect from both subnets to this server, and the server is
able to reach the outer world.

but i cannot ping from one subnet to the second subnet... i checked
ip_forward=1... i know it must be something very stupid, but i just
don't see it.
i checked iptables, they are empty and default policy is ACCEPT.

i'm running debian sarge, kernel 2.6.9, 2.6.8 or 2.6.13.1 (always the
same problem).
kernel 2.6.13.1 has no NETLINK option...

regards
moritz

 
Reply With Quote
 
 
 
 
Clifford Kite
Guest
Posts: n/a

 
      09-17-2005, 10:09 PM
(E-Mail Removed) wrote:
> hi


> all i want is to connect two networks:
> 172.17.0.0/16 and 172.18.0.0/16


> i followed several how-tos and manuals for setting up my machine, but
> something is odd and i don't figure out what.


> so this are my steps:
> ifconfig eth0 172.17.1.7 netmask 255.255.0.0 up
> ifconfig eth1 172.18.0.1 netmask 255.255.0.0 up


> ip route add net 172.17.0.0/16 dev eth0
> ip route add net 172.18.0.0/16 dev eth1
> ip route add default gw 172.17.0.1 dev eth0


Do all other hosts on 172.17.0.0/16 have 172.17.0.7 configured as
their default or 172.18.0.0/24 gateway?

Do all other hosts on 172.18.0.0/16 have 172.18.0.1 configured as
their default or 172.17.0.0/16 gateway?

> i can now connect from both subnets to this server, and the server is
> able to reach the outer world.


> but i cannot ping from one subnet to the second subnet... i checked
> ip_forward=1... i know it must be something very stupid, but i just
> don't see it.
> i checked iptables, they are empty and default policy is ACCEPT.


> i'm running debian sarge, kernel 2.6.9, 2.6.8 or 2.6.13.1 (always the
> same problem).
> kernel 2.6.13.1 has no NETLINK option...


> regards
> moritz



--
Clifford Kite Email: "echo xvgr_yvahk-(E-Mail Removed)|rot13"
PPP-Q&A links, downloads: http://ckite.no-ip.net/
/* In my book, the first poster to resort to personal abuse in a Usenet
debate loses by default. - Rod Smith */

 
Reply With Quote
 
Tim Lingard
Guest
Posts: n/a

 
      09-17-2005, 11:31 PM
On Sat, 17 Sep 2005 12:06:35 -0700, moritz wrote:

> hi
>
> all i want is to connect two networks:
> 172.17.0.0/16 and 172.18.0.0/16
>
> i followed several how-tos and manuals for setting up my machine, but
> something is odd and i don't figure out what.
>
> so this are my steps:
> ifconfig eth0 172.17.1.7 netmask 255.255.0.0 up
> ifconfig eth1 172.18.0.1 netmask 255.255.0.0 up
>
> ip route add net 172.17.0.0/16 dev eth0
> ip route add net 172.18.0.0/16 dev eth1
> ip route add default gw 172.17.0.1 dev eth0
>
> i can now connect from both subnets to this server, and the server is
> able to reach the outer world.
>
> but i cannot ping from one subnet to the second subnet... i checked
> ip_forward=1... i know it must be something very stupid, but i just
> don't see it.
> i checked iptables, they are empty and default policy is ACCEPT.
>
> i'm running debian sarge, kernel 2.6.9, 2.6.8 or 2.6.13.1 (always the
> same problem).
> kernel 2.6.13.1 has no NETLINK option...
>
> regards
> moritz


Is it because the class B netmask stops the subnets from reaching 172.x.x.x?

--tim

 
Reply With Quote
 
moritz@uplink-verein.ch
Guest
Posts: n/a

 
      09-18-2005, 08:51 AM
172.17.0.1 is the overall gateway. this means every packet with
destination world has to pass through this. the subnet 172.17.0.0/16 is
connected to this gateway. in addition i want to connect a second
subnet 172.18.0.0/16 to 172.17.0.0/16. so this means: all traffic from
172.18.0.0/16 goes through 172.18.0.1, which is 172.17.1.7 (so not the
overall gateway). from there it goes through the 172.17.0.1 to the
internet.

so i want to route a private network through another private network to
the internet.

regards
moritz

 
Reply With Quote
 
Kurt
Guest
Posts: n/a

 
      09-19-2005, 04:35 AM

It's not a problem routing a private network to the internet via another
private network, but you do have to have your routes set up somewhere.
Simply connecting the interfaces and setting up the computer to route
between interfaces won't do it. If computers on the 172.17.0.0 network
point to 172.17.0.1 as their default gateway, then you'll need to add a
route to the 172.17.0.1 router that points traffic destined for the
172.18.0.0 network via 172.17.1.7. Computers on the 172.18.0.0 network
should use 172.18.0.1 as their gateway, and the box you're using for
your router should have a single default gateway, 172.17.0.1. If you
don't have access to the router, you could add the routes directly on
the computers for LAN-to-LAN, but you'll need the route on the router if
you want the 172.18 network to have Internet.

....kurt


(E-Mail Removed) wrote:
> 172.17.0.1 is the overall gateway. this means every packet with
> destination world has to pass through this. the subnet 172.17.0.0/16 is
> connected to this gateway. in addition i want to connect a second
> subnet 172.18.0.0/16 to 172.17.0.0/16. so this means: all traffic from
> 172.18.0.0/16 goes through 172.18.0.1, which is 172.17.1.7 (so not the
> overall gateway). from there it goes through the 172.17.0.1 to the
> internet.
>
> so i want to route a private network through another private network to
> the internet.
>
> regards
> moritz
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
PSE help: up a very simple routing lab Branlebāt Windows Networking 5 01-11-2008 03:20 PM
simple lan routing BW Windows Networking 7 04-27-2007 02:56 AM
Simple Routing ValeX Network Routers 19 04-11-2006 07:17 AM
Simple routing question about my setup Ken Williams Linux Networking 4 06-30-2004 11:07 PM
Help with simple routing calle Linux Networking 12 09-05-2003 02:01 PM



1 2 3 4 5 6 7 8 9 10 11