LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Cant get my routing network card to be active! (https://www.linuxquestions.org/questions/linux-networking-3/cant-get-my-routing-network-card-to-be-active-75814/)

im_not_jose 07-25-2003 08:16 AM

Cant get my routing network card to be active!
 
Ok, before anything, I would just like to let you know I'm still quite relatively new to Linux, having only measured its success by installing it every so often, which is fairly easy enough these days, and doing a few basic things.

Just recently I used old spare parts from an old PC to build into a customized case for use as a ROUTER for our home broadband internet connection. Specs are:
Intel PII 450,
Intel mobo,
S3 32 Video 4mb,
256 meg ram,
20 gig HD,
3COM Fast Ethernet 3C905B-TX 10/100,
Netgear Generic 10/100,
Any old CD drive

I installed Mandrake 9.0 (so, I know its not the best choice for a ROUTER distro, but its linux none-the-less and so it should be ok) and all my hardware was working fine. At first the broadband connection didnt work, which is connected to the 3COM net card, but after registering the MAC address with the provider, all was fine. I know the Netgear card works as well, because I registered that one as well and try connecting with it. All components worked.

Now, without having any clue, I tried to search for HOW-TO pages on the internet on how to setup a IP Gateway, so this machine can act as a ROUTER for the rest of our PC's sharing the internet connection. I had no knowledge of this, but eventually gathered that in LINUX it is called IP MASQUERADING. I found the following page to help:
w_w.ibiblio.org/pub/Linux/docs/HOWTO/other-formats/html_single/IP-Masquerade-HOWTO.html

I've followed through the instructions very carefully. I have done the following:
- Changed menuconfig options for which modules to be loaded and compiled into a new kernel
- Compiled the new kernel (and I believe this kernel compiled successfully, because many old warnings on bootup and INIT 6 have disappeared - compile / make modules took well over 5 hours!)
- Created firewall ruleset in /etc/rc.d/rc.firewall-2.4
and so forth...

Unfortunately, this does not seem to have done much. I can't seem to get my second network card (eth1 - Netgear) to bind to an IP address and I have tried to add it manually with IFCONFIG, but still other machines will not connect.

I've recompiled the kernel 2 times now (once with IPV6 removed), tried manually setting up the ROUTING table, but all comes to nothing.

At one point, it so nearly worked. eth1 was assigning itself an ip automatically and it got [OK] on boot, but then I changed its IP manually for some reason and have not beenable to get it back working since. Each time I boot up, the boot screen saws that it is able to determine the IP for eth0, but fails for eth1.

Help!

--Jose

bentz 07-25-2003 08:28 AM

Try to look at this one step at a time. Before you can configure the box for routing, you need to get the ethernet cards recognized by the kernel, and properly configured with ethernet addresses.

I've got no idea why you had to recomiple the kernel at all, the Mandrake 9 default, out of the box kernel should be just fine.

Which interface (eth0 | eth1) if the one connecting to your ISP?

Which interface (eth0 | eth1) if the one connecting to your home network?

If you don't have a DHCP server on your internal network, the home network interface absolutely needs to be static.

Once you've got both interfaces talking to thier associated networks, then you can begin to look at iptables for routing.

im_not_jose 07-25-2003 08:38 AM

bentz, thanks for your quick reply.

So you know, I'm very new to this. Preferably it would be nice to have the network running through DHCP, but for some reason, DHCPS isnt installed in /usr/sbin/ (???). Either way, our home network consists only of 4 PC's (most of them running Windows XP) so running a static IP network is fine, although having DHCP would be much easier.

Currently eth0 (3COM) is connecting to the broadband modem (cough, router) and eth1 (NETGEAR) is going to be for the internal network.

Why I had to recompile the kernel, I dont know. Im just starting to get a grasp of LINUX and so I followed the documentation and presumed that perhaps some of the modules weren't compiled into the kernel. I have still kept the old kernel, so I can always boot to that one in LILO.

I sort of understand things, and yet I havent got a clue. I spent a lot of time trying to find information on the internet, which helps a newbie like me so that I have a basic foothold on things, but so far I've had to dive into the deep end, therefore I dont completely understand what I really need to do and why.

bentz 07-25-2003 09:26 AM

I would eventually consider using DHCPd on your home network to distribute IP addresses to your XP machines. Understand however, that if the Linux gateway/router/dhcp server is to function, it needs to have a static address assigned to it. All the other machines on your home network can be DHCP.

If sounds like your external interface for your cable modem (eth0) is working properly. What you need to do next is to configure a static address for your internal interface (eth1) and ensure that it's visible (pingable) from your XP machines.

im_not_jose 07-25-2003 10:11 AM

bentz, thanks again.

however, I was wondering if possible you could give me a little advice on doing this. Dhcpd isnt installed and I dont know why. Where do I get it from? What do I do next?

Thanks again!

camelrider 07-25-2003 10:19 AM

The output from ifconfig -a would be useful to see if both your cards are "UP BROADCAST RUNNING..."

Are the other machines on your network configured to look to your router as their defaultroute?

im_not_jose 07-25-2003 10:57 AM

eth0 is:
"up broadcast running"
eth1 is, however, not, as it says:
"broadcast notrailers multicast"
and has no IP or mask.

I have, however, not set eth1 to any specific ip. and after running the Mandrake Control Center -> Network & Internet -> Connection, it says:
Interface: eth1
IP Address:
Protocal: DHCP
Driver: tulip
State: down

I have tried to manually changed this to:
Interface: eth1
IP Address: 192.168.0.1
Protocal: DHCP

However, eth1 still remains down in the Mandrake Control Center screen and when running ifconfig.

???

I have tried to get the other machines to be configured to my router, but since I cannot get eth1 to work, I havent spent much time testing this.

im_not_jose 07-25-2003 11:04 AM

another thing is that I cant seem to find where to install dhcpd from, as it is not installed. it isnt on the mandrake cds!

im_not_jose 07-25-2003 11:50 AM

Ok, ive managed to find DHCP on the cd and installed DHCPD... er, what next?

also, i am unable to ping myself on either eth0 or eth1 from the linux box

im_not_jose 07-25-2003 12:28 PM

ok,I have managed to setup DHCPD, so now eth0 (external card) is running DHCP (because the modem isnt static, and eth1 is STATIC (192.168.1.1).DHCPD is working and from a Windows XP computer I have managed to get the network card to recognize the DHCP server and it assigns itself:
IP - 192.168.1.235
Subnet Mask - 255.255.255.0
Gateway - 192.168.1.1

Everything working just fine! Except that despite this, no packets are routing to the client pc... the usual test of firing up internet explorer to Google fails and I cannot ping 192.168.1.1 (eth1 on the server).

Whats going wrong?


Oh, and forgive my ignorance, but does the server need to use an XPATCH network cable intead of the usual, because I read somewhere on this forum that someone was doing it this way.


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