Click to See Complete Forum and Search --> : Redhat 7.3 eth1 fail determining IP


buton
08-16-2002, 03:08 AM
I have a Redhat 7.3 linux system that has the isp connection through eth0 which works fine, using a netgear ethernet card fa311. I am trying to get it to serve to my xp system, but the boot up fails and I have tried to activate it, the eth1 card is a D-link 530tx+. Rhine has configured both cards. I did ifconfig to see if i could find anything, but i have only a couple days of linux experience. I have used a little bit of the search button, but didn't seem to see a post about 7.3. what should the localhost addresses be? what should be the other computer addresses?




ifconfig
eth0 Link encap:Ethernet HWaddr 00:A0:CC:A1:6B86
inet addr:192.168.1.2 Bcast:192.168.1.3 Mask:255.255.255.252
UP BROADCAST NOTRAILERS RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1324 errors:0 dropped:0 overruns:0 frame:0
TX packets:1463 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:100
RX bytes:1023162 (999.1 Kb) TX bytes:37 9610 (370.7 Kb)
Interrupt:10 Base address:0xa00

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX Packets:59 errors:0 dropped:0 overrun:0 frame:0
TX packets:59 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0
RX bytes:3845 (3.7 Kb) TX bytes:3845 (3.7 Kb)

nomo_green
08-16-2002, 04:12 PM
not sure if that card is supported, only card i see on the hcl at redhat is the DFE-550tx.

anyways, you can try running neat. /usr/bin/neat as root. this should allow you to easily configure your eth1.

localhost address should be 127.0.0.1
other depends on how they are configured

buton
08-16-2002, 10:53 PM
I think the network card is working fine, i think it is a networking problem. currently i have the eth-1 on the dhcp setting. I had it a static but it wasn't working for the time being. what kind of settings if i used #netconfig IP, netmask, gateway, and primary nameserver? and what would I do on my winxp system to recognize the server? i have been unable to activate eth1, but i have been able to ping from the xp computer on the loop back i don't know if that means anything, probably not.

#ifconfig -a

eth0 Link encap:Ethernet HWaddr 00:A0:CC:A1:6B86
inet addr:192.168.1.2 Bcast:192.168.1.3 Mask:255.255.255.252
UP BROADCAST NOTRAILERS RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1324 errors:0 dropped:0 overruns:0 frame:0
TX packets:1463 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:100
RX bytes:1023162 (999.1 Kb) TX bytes:37 9610 (370.7 Kb)
Interrupt:10 Base address:0xa000

eth1 Link encap:Ethernet HWaddr 00:50:BA:C0:9B:24
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:5 errors:0 dropped:0 overruns:0 frame:0
TX packets:8 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:100
RX bytes:300 (300 b) TX bytes:4720 (4.6 Kb)
Interrupt:11 Base address:0xbf00

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX Packets:59 errors:0 dropped:0 overrun:0 frame:0
TX packets:59 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0
RX bytes:3845 (3.7 Kb) TX bytes:3845 (3.7 Kb)

resolve.conf

search localdomain
nameserver 192.168.1.1

dhcpcd-eth0.info

IPADDR=192.168.1.2
NETMASK=255.255.255.252
NETWORK=192.168.1.0
BROADCAST=192.168.1.3
GATEWAY=192.168.1.1
DNS=192.168.1.1
DHCPSID=192.168.1.1
DHCPGIADDR=0.0.0.0
DHCPSIADDR=192.168.1.1
DHCPCHADDR=00:A0:CC:A1:6B:86
DHCPSHADDR=00:05:D8:06:C6:13
DHCPSNAME=
LEASETIME=86400
RENEWALTIME=43200
REBINDTIME=64800
INTERFACE=eth0
CLASSID="Linux 2.4.18-3 i686"
CLIENTID=00:A0:CC:A1:6B:86

no such file as dhcpcd-eth1.info

what would i look for do i want dhcp to configure my internal network? I have tried to use the Easy Internet Sharing NHF how to advice but it just made my internet connection fail, so i reverted back.

buton
08-17-2002, 11:58 AM
I still having problems. so i included the #route


Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.1.0 * 255.255.255.252 U 0 0 0 eth0
192.168.0.0 * 255.255.255.0 U 0 0 0 eth1
127.0.0.0 * 255.0.0.0 U 0 0 0 lo
default 0.0.0.0 UG 0 0 0 eth0

buton
08-17-2002, 12:42 PM
I am kind of curious about my xp maybe it is being a little pain, so here is the routing.
route PRINT

Window xp client configuration
Routing

Network Destination/ Netmask / Gateway/ Interface/ Metric
127.0.0.0/ 255.0.0.0/ 127.0.0.1/ 127.0.0.1/ 1
169.254.0.0/ 255.255.0.0/ 169.254.49.122/ 169.254.49.122/ 20
169.254.49.122/ 255.255.255.255/ 127.0.0.1/ 127.0.0.1/ 20
169.254.255.255/ 255.255.255.255/ 169.254.49.122/ 169.254.49.122/ 20
224.0.0.0/ 240.0.0.0/ 169.254.49.122/ 169.254.49.122/ 20
255.255.255.255/ 255.255.255.255/ 169.254.49.122/ 169.254.49.122/ 1

Cadillac84
08-17-2002, 03:08 PM
Notice that your netmask on eth0 is 255.255.255.252

That's kind of curious! What it means is that there are only 2 devices on that net -- nothing wrong with that, just curious (to me).

Anyway, the IP of 192.168.x.x tells you it is a private network and that your "cable-modem" or "dsl-modem" is translating the network address seen by the outside world. This is a good thing!

OK, now for eth1

You will create your own private network and you don't need to ask anybody what numbers to use as long as we're talking about a finite number of computers under your control.

If this is a large installation, you need to talk to your SysAdmin about the net address.

But, assuming you are talking about less than 253 computers . . .

select your private network address such as

192.168.37.0
or
192.168.21.0
or
10.10.14.0
stick to 192.168 and 10.10 and you'll be fine. The third number comes out of your imagination (but you can't use 1 because your other card (eth0) is already using that and this needs to be a different network).

192.168.1.0 is a network, 192.168.2.0 is another network, 192.168.3.0 is another, etc.

Let's just say that 37 is your favorite number.

So, we'll make your net 192.168.37.0

Your host (the "router") will be the #1 machine in the net, so give it the number 192.168.37.1

The broadcast address is always 255, so here's how you get the eth1 cranked up

ifconfig -v eth1 192.168.37.1 netmask 255.255.255.0 up

Linux will know that 0 is the net and 255 is broadcast, so you don't have to tell it about that.

the "up" brings the card UP (on line) and when you next type

clear ; ifconfig

you should see eth0, eth1, and lo

Try it -- it'll be just fine.

Now, when you assign IPs to your other computers on the private (internal) network, you will manually assign an IP to each using the scheme 192.168.37.2 which will have as its gateway the machine 192.168.37.1 and its mask will be 255.255.255.0 as will the mask for every computer you have. Now, the fourth number can be whatever you want -- just don't use 0, 1 or 255 and don't use the same number twice.

You can have 253 computers in addition to your "router" and if you have that many, you might want to get a T-1 line instead of cable or ADSL (LOL).


Chuck Moore
CNMoore@Knology.net

buton
08-17-2002, 05:00 PM
Thank you for the advice, I have the setup going and I am able to ping the computers back and forth between the network. Now I am still having problems with the internet sharing. I am able to access the net on the linux machine but i am unable to access the net from the winxp machine. The network is a small home network only 3 computers.

ISP---->DSLmodem---->eth0----->Linux---->eth1------>switch----->winxp client

My question would be what could be happening that won't let me share internet services with the winxp client computer?

Cadillac84
08-21-2002, 11:52 PM
Don't want to spend too much time on this in case you've already got it going and don't need help anymore.

But, things to check:

make sure ip_forwarding is enabled by running the following test.

I guess we're supposed to put # in front of our examples so people who read these with Linux don't end up running scripts that mess up their composters!

# cat /proc/sys/net/ipv4/ip_forward

if the answer comes back "0" you need to change it to "1" using the command:

# /bin/echo 1 > /proc/sys/net/ipv4/ip_forward

Then run the other one again just to make sure.

In RedHat, you can't set any rules until you've done that.

I use "ipchains" which isn't the best idea. Look around in here for some info on "iptables" and you should be able to get the thing working quickly.

If you can, go to your XP machine and get to a command prompt.

# ping -n 1 192.168.x.x (with that IP being whatever you've got eth1 set for. If that comes back OK, then do it again but use the IP you've got eth0 set for. If that comes back, go to the Linux box and type:

# lynx

I assume lynx will come up. Touch the letter "g" and type in the IP of some known place like http://64.58.76.225 and touch Enter. You should get the Yahoo home page. If you do, then all is well with your pipeline.

Now, type "g" again and when it asks for the url, type in "www.google.com" and Enter. If you get google's search page, you know you have a DNS route set up.

Assuming all of that works, all you need to do is set a few rules in your iptables and you'll be working in no time!

There's plenty of discussion about iptables in this section. Look for it.

Best wishes,

Chuck Moore
CNMoore@Knology.net