[NTLUG:Discuss] Troubleshooting a network connection - fixed

LEROY TENNISON leroy_tennison at prodigy.net
Fri May 12 23:57:16 CDT 2006


I missed Terry's comment about system-config-network and did a lot of research before re-reading email and noticing it.  Thanks Terry.
 
 Since I didn't get any other replies (and am GUI-adverse) I spent a fair amount of time researching to find some answers.  I'll share what I found with everyone in the hope that it saves someone else the trouble.  I'm also asking if some of you would sanity check my "findings" on distros other than CentOS to confirm or deny that they are generally applicable.
 
 How does Linux decide which NIC is going to be eth0, eth1, and so on?
 
 Articles I found on the Web indicated that this varied, mainly as Linux itself changed.
 
 
 How do I tell what driver is being used for eth0 and eth1. - Several possibilities:
 
 ifconfig lists the 'traditional' (non-PCI) interrupt and base addresses of the card being used, /proc/ioports may list a base address and associate a name or PCI interrupt with it (my SIS900 card listed sis900, my 3Com 905B only had it's PCI interrupt listed - use lsmod in this situation)
 
 dmesg | less and search for the string 'divert'.  On CentOS messages above these entries listed the driver, 'traditional' interrupt and PCI interrupt How do I tell what driver is being used for eth0 and eth1.
 
 ethtool -i eth? listed the driver and PCI interrupt (labeled 'bus-info')
 
 
 Anyone know where the format of ifcfg-eth0, ifcfg-eth1 and so on is documented?
 
 Well, it depends.  Searching www.redhat.com/docs for 'ifcfg-eth' found a good description (at least of what I found on CentOS).  The SuSE Linux Administration Guide said they were documented in 'man ifup' (not true on CentOS).  Other Web entries had partial lists of the parameters.  This one seems to be more "iffy" and distro-dependent.
 
 
 Now, would anyone like to check their systems (preferably NOT Red Hat since CentOS is a clone of RHEL) and see if any of the ifconfig, /proc/ioports, dmesg and ethtool options applies more generally?  Thanks.
 
Fred Hensley <fred.hensley at comcast.net> wrote: Glad to read Leroy discovered and corrected his issue.

That being said, I recall that someone earlier wrote about the benefits 
and simplicity of setting up an IPCOP firewall instead.  That same 
ridiculously easy IPCOP installation described earlier includes a 
purposeful configuration/mapping of ethernet interfaces to IPCOP 
security zones.  And, after all is said and done, you can save the 
completed configuration (with our without hardware mappings) to an 
offline for quick restoration to a new server later.  Game, set, match...

My $0.02 added, end of commercial, and back to your original CentOS 
programming....

Cheers,

-Fred-

Fred Hensley
fred.hensley at comcast.net

Terry Henderson wrote:
> On 5/11/06, LEROY TENNISON  wrote:
>   
>> As usual I stumbled across the solution quite by accident (or maybe it was divine help). Noticed that the MAC address seemed different under Knoppix which led to the discovery that CentOS had selected opposite NICs for eth0 and eth1 from what Red Hat 9 used. This may be due to my starting out with only one NIC originally under RH9 and then adding the second later, it's been too long to remember. What I did was put
>>
>>  HWADDR= ...
>>
>> in both ifcfg-eth0 and ifcfg-eth1 (both in /etc/sysconfig/network-scripts, this path will be different for other distros such as SuSE).
>>
>>  This raises a couple of questions:
>>
>>  How does Linux decide which NIC is going to be eth0, eth1, and so on?
>>     
>
> The question is not "How does Linux decide which NIC is going to be
> eth0"  but rather how does the install program "decide which NIC is
> going to be eth0"
>
> There are applications such as "system-config-network" that allow you
> to manipulate address settings  for your NICs (and it also shows  you
> the driver module assignments as well).
>
> ("system-config-network"  is particular to Fedora)
>
>
>   
>> How do I tell what driver is being used for eth0 and eth1. 'ifconfig' gives me the hardware address and IP configuration but doesn't tell me what driver.
>>
>>  Anyone know where the format of ifcfg-eth0, ifcfg-eth1 and so on is documented?
>>
>>  Thanks for the help.
>>
>> _______________________________________________
>> http://ntlug.pmichaud.com/mailman/listinfo/discuss
>>
>>     
>
>
>   


_______________________________________________
http://ntlug.pmichaud.com/mailman/listinfo/discuss



More information about the Discuss mailing list