Quantcast
Channel: All EdgeRouter posts
Viewing all articles
Browse latest Browse all 60861

Re: LAN to Lab subnet

$
0
0

hiko wrote:

@vno

I don't disagree since I'm totally a newbie in networking but if a route needs to have a gateway in its own subnet, how do we route different subnets ?


You have a router on each of those subnets.

 

Networking is kind of like a tree.

 

 

                                       (WAN)
|
router_1 | | +-----------+------------+ | | | | (192.168.1.0/24) (192.168.2.0/24) | | router_2 router_3 | | (172.16.1.0/24) (172.16.2.0/24) | | +----------+ +------------+ | | | | host_a host_b host_c host_d | | | | (.1.10) (.1.11) (.2.100) (.2.101)

 

Routing tables will look like this:

Router_1 (192.168.1.1 / 192.168.2.1)

 

0.0.0.0/0 via (WAN_Gateway), eth0
192.168.1.0/24 directly connected, eth1
192.168.2.0/24 directly connected, eth2
172.16.1.0/24 via 192.168.1.100, eth1
172.16.2.0/24 via 192.168.2.100, eth2

 

 

Router_2 (192.168.1.100)

0.0.0.0/0 via 192.168.1.1, eth0
192.168.1.0/24 directly connected, eth0
172.16.1.0/24 directly connected, eth1

Router_2 (192.168.1.100) (ALTERNATE, NO WAN ACCESS) 

192.168.1.0/24 directly connected, eth0
192.168.2.0/24 via 192.168.1.1, eth0
172.16.1.0/24 directly connected, eth1
172.16.2.0/24 via 192.168.1.1, eth0

 

 

Router_3 (192.168.2.100)

0.0.0.0/0 via 192.168.1.1, eth0
192.168.2.0/24 directly connected, eth0
172.16.2.0/24 directly connected, eth1

 

Router_3 (192.168.2.100) (ALTERNATE, NO WAN ACCESS)

192.168.2.0/24 directly connected, eth0
192.168.1.0/24 via 192.168.1.1, eth0
172.16.2.0/24 directly connected, eth1
172.16.1.0/24 via 192.168.1.1, eth0

 

 Hosts A, B

0.0.0.0 via 172.16.1.1, eth0
172.16.1.0/24 directly connected, eth0

Hosts C, D 

0.0.0.0 via 172.16.1.1, eth0
172.16.1.0/24 directly connected, eth0

 

You could also give fuller routing tables to the hosts, but I'm getting tired of writing them (they'd look similar to the "alternate" entries for the routers)

 

 

 

 


hiko wrote:

 

Once again maybe it's a crazy setup since I don't know a lot in networking but it was working fairly well. I never really had the need of being able to communicate from the LAN to the LAB but now that I need it my setup looks to be incompatible.


 Nah, the setup should work fine, you've just got routing messed up somewhere.


Viewing all articles
Browse latest Browse all 60861

Trending Articles