Wireless Networking 2 Routers & Secure Shared Internet

Bookmark this page:  YahooMyWeb Yahoo!  Google Google  Windows Live Favorites Windows Live  del.icio.us del.icio.us  digg digg  Add to Netscape Netscape
Subject Author Date
2 Routers & Secure Shared Internet hufaunder@yahoo.com 06-21-08
Posted by hufaunder@yahoo.com on June 21, 2008, 1:14 am
Please log in for more thread options
I want to share an internet connection but have two separate LANs so
computers from one LAN can't access shared files on computers on the
other LAN, i.e.

/-->LAN1
Modem-->Router1--
\-->Router2-->LAN2

Both LANs will have static and dynamic IP addresses.

Router1 has the following setup:
Router Address: 192.168.1.254
Subnet Mask: 255.255.255.0
DHCP Range: 192.168.1.64 - 253
Default Gateway: 192.168.1.254

Router2 is currently setup like this:
Router Address: 172.168.1.1
Subnet Mask: 255.255.255.0
DHCP Range: 172.168.1.100 - 149
Default Gateway: 172.168.1.1

Router1 and Router2 are connected together with a CAT5 cable using a
LAN (not WAN) port on each side.

However, I can't access the internet from a computer connected to
LAN2. How do I setup Router 2 correctly? If it matters it's a Linksys
WRT54GC.

Thanks

Posted by Mr. Arnold on June 21, 2008, 9:35 am
Please log in for more thread options

>I want to share an internet connection but have two separate LANs so
> computers from one LAN can't access shared files on computers on the
> other LAN, i.e.
>
> /-->LAN1
> Modem-->Router1--
> \-->Router2-->LAN2
>
> Both LANs will have static and dynamic IP addresses.
>
> Router1 has the following setup:
> Router Address: 192.168.1.254
> Subnet Mask: 255.255.255.0
> DHCP Range: 192.168.1.64 - 253
> Default Gateway: 192.168.1.254
>
> Router2 is currently setup like this:
> Router Address: 172.168.1.1
> Subnet Mask: 255.255.255.0
> DHCP Range: 172.168.1.100 - 149
> Default Gateway: 172.168.1.1
>
> Router1 and Router2 are connected together with a CAT5 cable using a
> LAN (not WAN) port on each side.
>
> However, I can't access the internet from a computer connected to
> LAN2. How do I setup Router 2 correctly? If it matters it's a Linksys
> WRT54GC.
>
The non gateway/second router must be converted to be a switch and not a
router, by disabling the DHCP server on the second router.

Then the router that is now a switch, will be configured to use an IP,
subnet mask, and gateway IP on the gateway router, which the IP should not
be a DHCP IP on the gateway router but a static. Then the machines on the
gateway router and the now the router converted to be a switch can see each
other.

It doesn't make a difference if the two routers are wire, wireless or one is
wire and one is wireless.


Posted by hufaunder@yahoo.com on June 21, 2008, 8:03 pm
Please log in for more thread options
Thanks for the reply. However, my goal is to have two separate
networks, i.e. the computers on LAN1 don't see the computers on LAN2
and visa versa. A switch won't do that. I would need at least a
bridge, I think.

So with the above scenario I think I need DHCP on both router boxes,
router1 will automatically give IP addresses to the computers
connected on LAN1 and router2 will automatically give IP addresses to
computers connected to LAN2.

Note that on router two I see two DHCP configurations. One is
InternetSetup->Internet Connection Type->DHCP/Static/PPPoE/PPTP. The
other one is under Network Setup->DHCP Server Settings->DHCP Server
enabled/disabled.

The problem is that I have router2 connected to router1 using a LAN
port on each side. So router1 tries to assign IP addresses for devices
on the switch of router2 and visa versa. So how do I avoid that
conflict but still allow automatic assignment of IP addresses both on
LAN1 and LAN2?

Thanks


>
>
>
>
> >I want to share an internet connection but have two separate LANs so
> > computers from one LAN can't access shared files on computers on the
> > other LAN, i.e.
>
> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 /-->LAN1
> > Modem-->Router1--
> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 \-->Router2-->LAN2
>
> > Both LANs will have static and dynamic IP addresses.
>
> > Router1 has the following setup:
> > Router Address: 192.168.1.254
> > Subnet Mask: 255.255.255.0
> > DHCP Range: 192.168.1.64 - 253
> > Default Gateway: 192.168.1.254
>
> > Router2 is currently setup like this:
> > Router Address: 172.168.1.1
> > Subnet Mask: 255.255.255.0
> > DHCP Range: 172.168.1.100 - 149
> > Default Gateway: 172.168.1.1
>
> > Router1 and Router2 are connected together with a CAT5 cable using a
> > LAN (not WAN) port on each side.
>
> > However, I can't access the internet from a computer connected to
> > LAN2. How do I setup Router 2 correctly? If it matters it's a Linksys
> > WRT54GC.
>
> The non gateway/second router must be converted to be a switch and not a
> router, by disabling the DHCP server on the second router.
>
> Then the router that is now a switch, will be configured to use an IP,
> subnet mask, and gateway IP on the gateway router, which the IP should no=
t
> be a DHCP IP on the gateway router but a static. Then the machines on the
> gateway router and the now the router converted to be a switch can see ea=
ch
> other.
>
> It doesn't make a difference if the two routers are wire, wireless or one=
is
> wire and one is wireless.- Hide quoted text -
>
> - Show quoted text -


Posted by Bill Kearney on June 27, 2008, 6:54 pm
Please log in for more thread options

>I want to share an internet connection but have two separate LANs so
> computers from one LAN can't access shared files on computers on the
> other LAN, i.e.
>
> /-->LAN1
> Modem-->Router1--
> \-->Router2-->LAN2

By doing this the devices on LAN2 will be double NAT routed.

Devices on LAN2 could see everything on LAN1.
Devices on LAN1 would not be able to see anything on LAN2

What are you really trying to do?

The easier solution would be to get a 2nd external IP address from your ISP
and set them up through a switch:

Modem
|
[switch]
| |
| +---[router1]----LAN1
+------[router2]----LAN2

Each router having it's own external IP address. Not usually all that much
more per month.

Otherwise you'd be better served adding a THIRD router and putting it in
place of the above [switch] device. Then configure the router1 and router2
devices as routers, not gateways. That way the 3rd router will act as a
gateway for both of them.

Doing this way will be easier to configure/maintain when using
consumer-grade devices like the linksys. Doing this with more sophisticated
office-grade devices would be different, but more expensive.

-Bill Kearney


Posted by Pierre Asselin on June 29, 2008, 7:34 pm
Please log in for more thread options
Responding a little late, I was away...

> I want to share an internet connection but have two separate LANs so
> computers from one LAN can't access shared files on computers on the
> other LAN, i.e.

> /-->LAN1
> Modem-->Router1--
> \-->Router2-->LAN2
> [ ... ]
> How do I setup Router 2 correctly? If it matters it's a Linksys
> WRT54GC.

It probably matters. You're in luck.


> Both LANs will have static and dynamic IP addresses.

> Router1 has the following setup:
> Router Address: 192.168.1.254
> Subnet Mask: 255.255.255.0
> DHCP Range: 192.168.1.64 - 253
> Default Gateway: 192.168.1.254

> Router2 is currently setup like this:
> Router Address: 172.168.1.1
> Subnet Mask: 255.255.255.0
> DHCP Range: 172.168.1.100 - 149
> Default Gateway: 172.168.1.1

> Router1 and Router2 are connected together with a CAT5 cable using a
> LAN (not WAN) port on each side.

No. Connect Router2 WAN to a Router1 LAN port with a crossover
cable. If Router1 has an "Uplink" port you can use a regular cable
from that to Router2 WAN but that consumes the adjacent LAN port
on Router1. (If the routers have MDI/MDIX ports you can use any
cable, but I don't think the Linksys routers do that.)

Next, set Router2 to "router" mode as opposed to "gateway" mode.
Set the WAN parameters manually on Router2.
address 192.168.1.10 (on Router1's LAN range but out of DHCP range)
subnet 255.255.255.0
default gateway 192.168.1.254 (Router1 as seen from its LAN)

You probably need a static route on Router1,
destination LAN 172.168.1.0 netmask 255.255.255.0
gateway 192.168.1.10 (Router2 as seen from its WAN port)
interface LAN

You mentioned in another post that you *don't* want LAN1
to see computers on LAN2. That's unusual, but you can
do this by a firewall rule (maybe "filters" on the menus).
Have LAN2 drop anything from 192.168.1.0/24 so that
only packets with an external Internet address come through.

Good luck.

--
pa at panix dot com

Similar ThreadsPosted
2 Routers & Secure Shared Internet June 21, 2008, 1:14 am
Shared Internet Connection Problem January 27, 2005, 2:41 pm
Shared internet access via mobile phone September 20, 2005, 8:46 pm
i cannot access shared internet over the router..plizz help.. February 5, 2008, 2:04 am
Shared Internet access in Finnish housing cooperatives March 7, 2005, 3:26 pm
Shared Internet access in Finnish housing cooperatives March 7, 2005, 4:07 pm
Shared wireless Internet connection and VoIP adapter March 19, 2006, 9:10 am
Secure my internet wireless July 27, 2006, 12:19 pm
ISPs kicking routers off internet? July 18, 2006, 1:43 am
wireless routers drop internet connection October 15, 2007, 2:26 pm
How to connect two routers wirelessly and access internet through the guest router? July 10, 2007, 6:52 am
WEP Shared or Open Key???? November 23, 2004, 5:58 am
Can't see shared printer from one PC.. February 21, 2006, 10:30 pm
Shared Router October 13, 2007, 4:42 am
WiFi WPA Pre-Shared Key standard April 14, 2006, 5:51 pm