LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-25-2006, 05:08 PM   #1
DrKranium
LQ Newbie
 
Registered: Jan 2005
Posts: 8

Rep: Reputation: 0
how to connect two lans?


I have a LAN (LAN1) that is working well and is connected to the internet. There is also a 2nd LAN (LAN2).

The nodes in LAN2 are connected to one another through netgear's WGT624 wireless router. All nodes in LAN2 can ping eachother. But this router has no connection to the internet. However one node (192.168.1.100) in LAN2 is also a node (192.168.0.100) on LAN1 so it can see the internet.

I have two questions:
1) How do I get WGT624 to send all packets from other machines through 192.168.1.100?
2) Then, do I use Masquerading to forward all requests from LAN2 to LAN1?
 
Old 08-25-2006, 06:35 PM   #2
Brian1
LQ Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 65
need a bit more info about hardware.
What is lan 1 using to connect to the internet?
Is lan1 a mix of wireless and wired or just wired?

If lan1 is on a wired router then how about making the wgt624 the main router and connect as many machines to this router. Leave one etherport open. With a cross over cable connect from lan1 router to the lan side of the other router. No connection to the wan side of router2. Now turn off any DHCP and set the wan side to something like 192.168.50.100. Something not used any where elses. Now the machines connected to the second router will either get an IP from the first router or if static use the same class C IP range as it is using and use the gateway on the lan side of router1. So in essence the second router is only using the switch portion of the device.

Brian1
 
Old 08-26-2006, 01:33 PM   #3
DrKranium
LQ Newbie
 
Registered: Jan 2005
Posts: 8

Original Poster
Rep: Reputation: 0
more information

The first router is a wireless Actiontec DSL router. It is my only option for an internet connection.

So I really need to know how to get all nodes from LAN2 to reach the internet through linux box 1 (lb1). lb1 is connected wirelessly to LAN1 (the actiontec router) and wired to LAN2.
 
Old 08-27-2006, 12:09 PM   #4
Brian1
LQ Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 65
Ok if I understand this the Aciontec DSL router is connected to the Internet. Then the Linux Box 1 connects to it wirelessly. Now you have a wired nic in Linux Box 1 and connect them to lan 2 machines.
Is this correct?
How do you wish to use the netgear?
Option:1 Leaving machines on lan2 to talk to each other and to Linux box 1 but not allow Linux Box 1 to connect to services on lan2.
Option:2 Have all machines on lan2 to talk to each other and have Linux box 1 but also allow Linux Box to connect to services on lan2.
I would go Option:1 so as to leave the linux box as a more secure router/firewall. Actually I doubt there is much difference.

Before going on lets make sure we are on the same page with your setup
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem in routing between two LANs burrito Linux - Networking 2 07-03-2005 08:33 PM
Routing through 2 LANs LeifWiderberg Linux - Networking 3 03-12-2004 11:00 AM
Linux distributions and LANS Stimz Linux - Newbie 8 03-09-2004 02:58 AM
iptables and ftp from the LANs fddi1 Linux - Networking 4 10-17-2001 12:19 PM
LANs andymay27 Linux - Networking 1 10-14-2001 02:14 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:06 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration