Reply
JohnRo
Posts: 2
Registered: ‎09-11-2007

connect two networks with EG008W?

I have two networks, each with their own cable modem and attached devices. One is a WRT54G, the other a BEFSW11S4. One is using addresses in the 192.168.1.1 range and the other 10.1.1.1 Can I bridge these two networks using the EG008W switch and allow devices on one network to see devices on the other? Thanks! John
Expert
Expert
Posts: 12,649
Registered: ‎07-16-2006

Re: connect two networks with EG008W?

You'll create a single LAN then. Basically all ports in your network are the same then. You can connect any device to any port. If you use DHCP inside your LAN you'll have difficulties predicting which IP address any device may get because any device will get DHCP offers from both router.

It also depends if the router are able to route another subnet into the LAN or not. Some routers do this some not. If the router does not, you must configure the computers to do the correct routing of the other subnets traffic. Without those additional routes (on the router or the computer) traffic is simply forwarded to the router which forwards it to the ISP where it is dropped.

It is probably easier if you connect both networks with a router instead of a switch. Then both networks remain in different LANs and the router provides the connection between them. However, standard microsoft workgroup file sharing won't work with host names as name resolution for workgroups relies on broadcasts which won't cross the router. But you should be able to access shares in the other network using the IP address e.g. \\192.168.1.20\share
JohnRo
Posts: 2
Registered: ‎09-11-2007

Re: connect two networks with EG008W?

Thanks so much for the fast reply! I was hoping that it would indeed create one LAN. I thought that the multiple DHCPs could be an issue, but figured that each device would receive an address from the router it is connected to. Currently, only the routers are connected to the switch.

I think you've hit on something in that the routers may not be able to route another subnet. Currently with a computer on the 10.1.1.x router, I can (obviously) reach the 10.1.1.1 router, but can not see the router at 192.168.1.1.

I'll have to look into the router docs to see if I can change something. I also have a server that is hooked into each network (2 NICs), perhaps I could use this to bridge the two networks?

I should probably just combine it all into one LAN with a single ISP, but the second ISP is free and I was hoping I could maximize performance and minimize any bottlenecks by simply combining the two.

Thanks for your help,
John
Expert
Expert
Posts: 12,649
Registered: ‎07-16-2006

Re: connect two networks with EG008W?

The switch in the routers as well as the EG008W switch are just means to connect. Through switches everything is connected to each other and can communicate with each other. Only because you plug in a computer to a port on a router does not mean it gets an IP address from the DHCP server on that router. The computer is directly connected to both routers and it thus depends on many factors like the speed of DHCP server response and the selection algorithm of the DHCP client on the computer.

You won't even need the EG008W switch to connect the routers. It would be enough simply to connect one LAN port of the one router with a LAN port of the other router. It is basically the same setup except you have less ports available.

Re the routing: (exemplified) The default gateway of a computer is the router it got the DHCP IP address from, for example 192.168.1.1/255.255.255.0. Thus any traffic not going into the own LAN subnet 192.168.1.* will be sent to the router 192.168.1.1. By default, the router will forward any traffic outside its own LAN 192.168.1.* to the WAN port.

Things you can do to change this:

1. Add a manual static route for 10.1.1.0/255.255.255.0 to the local ethernet interface on the computers. This way the computers know where to find the 10.1.1.0 subnet.

2. Add a manual static route on the router. Again, you have to add a static router for 10.1.1.0 with subnet mask 255.255.255.0. The destination of this route is the LAN interface (with no gateway address). You may run into the problem on one or both routers that you cannot define a route which goes directly to the LAN interface and does not require a gateway IP address. If your router requires a gateway address for each static route you won't be able define the route you need.

With No. 2 all your traffic goes through the router initially. Make sure not to block incoming ICMP packets on the computers. The router will notify the computer via ICMP of the correct routing of the packets. This way the computer will learn to send the packets for 10.1.1.* directly to the LAN interface instead of forwarding it to the router 192.168.1.1.

If you already have a server with two NICs which is connected to both networks you can use that server for routing. You have to enable IP forwarding on the server. If both NICs have an IP address in either network you won't have to add any route on the server. The default routes which are added with the assignment of the IP address on the server will do all you need. With the server routing you still have to add a static route for the other network like above. The only difference now is that the destination is not the interface itself (i.e. use ethernet/ARP to find the final destination) but the server IP address as gateway.

Another advantage of the server as router between the subnets is that you can filter traffic between the subnets. You can limit what can be accessed between the subnets if necessary.

You can also define the server as bridge. But then you still have the same issues as before with the switch. Thus it is better to use the server as router.

You may want to have a look at some of the bigger routers like the Linksys RV series (RV016, RV042, RV082). Those routers have two WAN ports, thus you can connect two ISP lines to the router. Those two WAN ports can be used for load-balancing or for line backup. This way you can connect a single router to your lines. You have a single LAN subnet. And you can utilize both lines.