LinuxQuestions.org
Review your favorite Linux distribution.
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 07-29-2005, 07:26 PM   #1
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Rep: Reputation: 30
Atypical Gateway Configuration


I have an interesting problem. I have a computer that has a wired ethernet card in it. Unfortunately I cannot run a wire from the wireless router to the PC. Additionally there are no PCI slots so a wireless card cannot be installed. I have another desktop w/ FC4 on it that has an onboard ethernet card and uses a wireless card to get access to the internet.

Here is the question:

Can I run the FC4 machine as a gateway behind a router so I can use the other machine to get on the internet?

Here is the configuration

Internet---------> Wireless Router ------------> FC4 Gateway Box -------> Box 4 Net

If this is possible how would I do it?

The FC4 Gateway Box has the 192.168.x.x IP address scheme.

This is the goal I have in mind. The reason why I want the "Box 4 Net" to have internet access is because it lacks a Cd-ROM or Floppy drive. I want to install Gentoo on it. In order to do this I need it to have access to the internet and to setup a FTP server on the "FC4 Gateway Box" so I can initiate the Gentoo Installation.

Please let me know if this is confusing or if there is another way I could do this.

The help is much appreciated.
 
Old 07-29-2005, 08:42 PM   #2
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
Well, I'd be happy to get you installing Gentoo on a box!

Seriously, If I were you, I would look into "ethernet bridging" for your FC4 box. This will avoid needing it to be a gateway, and just allow the computers to all be part of the same "virtual LAN"
 
Old 07-29-2005, 11:17 PM   #3
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Original Poster
Rep: Reputation: 30
Is it very hard and do you think it would allow me to install gentoo on the cdrom and floppyless box through the network?
 
Old 07-30-2005, 09:41 AM   #4
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
If you can perform a cd-less install in gentoo, then I have no doubt that would work.
 
Old 07-30-2005, 12:41 PM   #5
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Original Poster
Rep: Reputation: 30
To be honest I've never performed a CD install in Gentoo and I'm confused by the instructions. I don't understand how the machine that is receiving the install will receive the correct IP information off of the network boot.

The machine that would store the install runs FC4 while the machine that is looking for the install currently has Windows 2000.

Do you have any tips for success?
 
Old 07-31-2005, 10:47 AM   #6
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Original Poster
Rep: Reputation: 30
Well I tried Ethernet Bridging and I couldn't get the machine I wanted to get the internet, also the machine that I setup the bridge on wouldn't get access to the internet.

Essentially this is the setup I'm aiming for




Internet-------------->Wireless Router----------> wlan0-->FC4 Box--- eth0---> MACHINE I WANT ON INTERNET

Where wlan0 is the interface that faces the internet and eth0 is the interface facing the machine I want on the internet.

I tried setting up a gateway also, but I couldn't get any activity on the eth0 interface. It was enabled and everything but when I looked on the back of my PC at the NIC there was no blinking lights or anything, also the computer connected to it said that the cable was unplugged. I tried multiple cables to rule out the possibility of a cable problem.

Can someone help me get the "MACHINE I WANT ON INTERNET" on the internet please? Also, just as a note that machine is running Windows 2000.
 
Old 07-31-2005, 12:11 PM   #7
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
To connect the two network cards directly together, you'll need to make sure you are using a crossover cable.
 
Old 07-31-2005, 02:39 PM   #8
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Original Poster
Rep: Reputation: 30
How come? It's just a gateway connection correct?
 
Old 07-31-2005, 03:13 PM   #9
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
In order to make two network cards talk directly to each other, you need a crossover cable, regardless of what you are doing in software.
 
Old 07-31-2005, 05:51 PM   #10
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Original Poster
Rep: Reputation: 30
Sorry i'm such a n00b I thought I would atleast get some activity with a regular cable.

This would be much easier if this box had a CD-ROM
 
Old 07-31-2005, 06:31 PM   #11
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
Yeah, it probably would. No chance of borrowing a CD-ROM from another machine?

About the cables... Ethernet uses 4 of the 8 pins in CAT5/RJ45. Each ethernet card has a receiver and a transmitter in it, each of which uses a pair of wires. With a straight-through cable, you get something like this:
Code:
TX ---------- TX
TX ---------- TX
RX ---------- RX
RX ---------- RX
Because of the crossover in a crossover cable, you get something more like this (sorry, couldn't draw diagnoals with ASCII art, had to rearrange pins)
Code:
TX ---------- RX
TX ---------- RX
RX ---------- TX
RX ---------- TX
 
Old 07-31-2005, 06:48 PM   #12
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Original Poster
Rep: Reputation: 30
Well the problem with the PC is that it's a small form factor machine and it takes a slim cd-rom that just plugs into the PC, much like a laptop. I'm looking at one on e-bay but I wanted to figure out an alternative in the mean time. I guess I'll just have to wait until I get a CD-ROM and do a networkless install
 
Old 07-31-2005, 06:50 PM   #13
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
If you can get a crossover cable and set up ethernet bridging (trivial, as I understand it), then you should be in business right now.
 
Old 07-31-2005, 06:54 PM   #14
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
For a bit more detailed information on network bridging, check out http://wiki.linuxquestions.org/wiki/Bridging_made_easy
 
Old 08-02-2005, 03:54 PM   #15
Centinul
Member
 
Registered: Jun 2005
Distribution: Gentoo
Posts: 552

Original Poster
Rep: Reputation: 30
Well I tried to setup a gateway but I'm having issues. My gateway box gets access to the internet fine but the windows 2000 box behind it can't get anything, can't even ping the gateway box.

I have my firewall configured like so:

Code:
iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
echo "1" > /proc/sys/net/ipv4/ip_forward
iptables -A INPUT -m --state ESTABLISHED,RELATED -j ACCEPT
iptables -A INPUT -m --state NEW -i ! wlan0 -j ACCEPT
iptables -A INPUT -p icmp -j ACCEPT
iptables -P INPUT DROP
when I do iptables -L the output reflects this code I put in.

For the internal side of the gateway box I have a cable running to the uplink side of a hub and I have the windows box plugged into that hub. There is an interesting problem though. The uplink port has a button that controls whether it is functioning as uplink or not. When I make it function as uplink the indicator lights go out on both the hub and the card on the gateway box, while if I turn off the uplink functionality the indicator lights will come on, on both the network card and the hub. I really think that is the root of my problem. I also tried another machine on a hub behind the gateway and it wouldn't work either.

for my setup eth0 = 192.1.168.50 <-- Internal NIC
which is what I have configured as the default gateway on the windows 2000 box.

I can't even ping the gateway box from the windows box.

What's going wrong?

Last edited by Centinul; 08-02-2005 at 04:10 PM.
 
  


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
a problem with debian box gateway configuration DRagonRage Debian 5 09-15-2005 07:30 AM
Gateway Configuration JustJD Linux - Networking 6 07-22-2005 01:47 AM
Configuration DHCP and Gateway on linux machine zowey Linux - Networking 4 04-03-2004 02:17 PM
internet gateway problems (iptables configuration) woranl Linux - Networking 11 08-27-2003 11:41 PM
two nic cards configuration for gateway red1526 Linux - Networking 3 03-06-2002 04:44 PM

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

All times are GMT -5. The time now is 02:46 PM.

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