|
The Ethernet-Howto contains detailed information on the current level of support for most of the common ethernet cards available. It covers common hardware configuration problems, and problems associated with choosing the right driver, and then getting that driver loaded and functional. It does not cover the next stages of setup (choosing an internet address, routing, etc). That information can be found in various other Linux documentation.
In the early days of linux, the old ISA type ethernet cards were the norm. The ISA bus had no sane or safe way for linux to determine what cards were installed, or what settings each card was to use. This meant that the end user was more involved in supplying this information to linux, and they turned to this guide for help on doing this.
Fortunately, the newer PCI bus can be found in nearly every computer that is out there today, and the ISA bus is left to collect dust with the 386 and 486 computers of yesteryear. The designers of the PCI bus recognized the problem with card detection on the old ISA bus, and so added support for each card to be able to communicate to the host computer their manufacturer and model, and what settings are to be used.
This slow demise of the ISA bus has reduced the involvement of the end user drastically. As such, most of today's linux users would not need to turn to this guide for help. However there are always some corner cases where things don't work as expected, or some problems that need troubleshooting. And of course there are still some old ISA computers out there doing thankless dedicated tasks in the bottom of dark closets too.
This present revision covers ethernet drivers found in kernels up to and including version 2.4.21. Some features pertaining to the upcoming 2.6 release are also mentioned.
The Ethernet-Howto is by:
Paul Gortmaker, p_gortmaker @ yahoo.com
The primary source of information for the initial ASCII-only version of the Ethernet-Howto was:
Donald J. Becker, becker @ scyld.com
who we should thank for writing a lot of the ethernet card drivers that are presently available for Linux.
This document is Copyright (c) 1993-2003 by Paul Gortmaker. Yes, I have been maintaing this thing for 10 years now! Please see the Disclaimer and Copying information at the end of this document ( copyright) for information about redistribution of this document and the usual `we are not responsible for what you manage to break...' type legal stuff.
New versions of this document can be retrieved from:
or for those wishing to use FTP and/or get non-HTML formats:
This is the `official' location - it can also be found on various Linux WWW/ftp mirror sites. Updates will be made as new information and/or drivers becomes available. If this copy that you are reading is more than 6 months old, then you should check to see if an updated copy is available.
This document is available in various formats (postscript, dvi, ASCII, HTML, etc.). I would recommend viewing it in HTML (via a WWW browser) or the Postscript/dvi format. Both of these contain cross-references that are not included in the plain text ASCII format.
As this guide is getting bigger and bigger, you probably don't want to spend the rest of your afternoon reading the whole thing. And the good news is that you don't have to read it all. The HTML and Postscript/dvi versions have a table of contents which will really help you find what you need a lot faster.
Chances are you are reading this document beacuse you can't get things to work and you don't know what to do or check. The next section ( HELP - It doesn't work!) is aimed at newcomers to linux and will point you in the right direction.
Typically the same problems and questions are asked over and over again by different people. Chances are your specific problem or question is one of these Frequently Asked Questions, and is answered in the FAQ portion of this document . ( The FAQ section). Everybody should have a look through this section before posting for help.
If you haven't got an ethernet card, then you will want to start with deciding on a card. ( What card should I buy...)
If you have already got an ethernet card, but are not sure if you can use it with Linux, then you will want to read the section which contains specific information on each manufacturer, and their cards. ( Vendor Specific...)
If you are interested in some of the technical aspects of the Linux device drivers, then you can have a browse of the section with this type of information. ( Technical Information)
As a quick overview, you need to: 1) have a plug in ethernet card or motherboard that has ethernet support built in, 2) determine the brand or make and model of the ethernet card or on-board ethernet chip, 3) determine if a linux driver for this model of card/chip does exist, 4) locate and load this driver, 5) check driver output to verify it found your card, 6) set or configure network parameters for the newly detected network interface.
Okay, don't panic. This will lead you through the process of getting things working, even if you have no prior background in linux or ethernet hardware.
First thing you need to do is figure out what model your card is so you can determine if Linux has a driver for that particular card. Different cards typically have different ways of being controlled by the host computer, and the linux driver (if there is one) contains this control information in a format that allows linux to use the card.
If you don't have any manuals or anything of the sort that
tell you anything about the card model, then you can try
using the lspci
utility for obtaining information
on the PCI devices in your computer. Doing a
cat /proc/pci
gives similar (but less) information.
For ISA cards, see the section on helping with mystery cards
(reference section:
Identifying an Unknown Card).
Now that you know what type of card you have, read through the details of your particular card in the card specific section (reference section: Vendor Specific...) which lists in alphabetical order, card manufacturers, individual model numbers and whether it has a linux driver or not. If it lists it as `Not Supported' you can pretty much give up here. If you can't find your card in that list, then check to see if your card manual lists it as being `compatible' with another known card type. For example there are hundreds, if not thousands of different cards made to be compatible with the original Novell NE2000 design.
Assuming you have found out that a linux driver exists for your card, you now have to find it and make use of it. Just because linux has a driver for your card does not mean that it is built into every kernel. (The kernel is the core operating system that is first loaded at boot, and contains drivers for various pieces of hardware, among other things.) Depending on who made the particular linux distribution you are using, there may be only a few pre-built kernels, and a whole bunch of drivers as smaller separate modules, or there may be a whole lot of kernels, covering a vast combination of built-in driver combinations.
Most linux distributions now ship with a bunch of small modules that are the various drivers. The required modules are typically loaded late in the boot process, or on-demand as a driver is needed to access a particualr device. You will need to attach this module to the kernel after it has booted up. See the information that came with your distribution on installing and using modules, along with the module section in this document. ( Using the Ethernet Drivers as Modules)
If you didn't find either a pre-built kernel with your driver, or a module form of the driver, chances are you have a typically uncommon card, and you will have to build your own kernel with that driver included. Once you have linux installed, building a custom kernel is not difficult at all. You essentially answer yes or no to what you want the kernel to contain, and then tell it to build it. There is a Kernel-HowTo that will help you along.
At this point you should have somehow managed to be booting a kernel with your driver built in, or be loading it as a module. About half of the problems people have are related to not having driver loaded one way or another, so you may find things work now.
If it still doesn't work, then you need to verify that the
kernel is indeed detecting the card. To do this, you need
to type dmesg | more
when logged in after the
system has booted and all modules have been loaded.
This will allow you to review the boot messages that the
kernel scrolled up the screen during the boot process.
If the card has been detected, you should see somewhere in
that list a message from your card's driver that starts with
eth0
, mentions the driver name and the hardware parameters
(interrupt setting, input/output port address, etc) that
the card is set for. (Note: At boot, linux lists
all the PCI cards installed in the system, regardless of
what drivers are available - do not mistake this for the
driver detection which comes later!)
If you don't see a driver indentification message like this, then the driver didn't detect your card, and that is why things aren't working. See the FAQ ( The FAQ Section) for what to do if your card is not detected. If you have a NE2000 compatible, there is also some NE2000 specific tips on getting a card detected in the FAQ section as well.
If the card is detected, but the detection message reports some sort of error, like a resource conflict, then the driver probably won't have initialized properly and the card still wont be useable. Most common error messages of this sort are also listed in the FAQ section, along with a solution.
If the detection message seems okay, then double check the card resources reported by the driver against those that the card is physically set for (either by little black jumpers on the card, or by a software utility supplied by the card manufacturer.) These must match exactly. For example, if you have the card jumpered or configured to IRQ 15 and the driver reports IRQ 10 in the boot messages, things will not work. The FAQ section discusses the most common cases of drivers incorrectly detecting the configuration information of various cards.
At this point, you have managed to get you card detected with
all the correct parameters, and hopefully everything is working.
If not, then you either have a software configuration error,
or a hardware configuration error. A software configuration
error is not setting up the right network addresses for the
ifconfig
and route
commands, and details of how
to do that are fully described in the Network HowTo and the
`Network Administrator's Guide' which both probably came on
the CD-ROM you installed from.
A hardware configuration error is when some sort of resource
conflict or mis-configuration (that the driver didn't detect
at boot) stops the card from working properly. This typically
can be observed in several different ways. (1) You get
an error message when ifconfig
tries to open the device
for use, such as ``SIOCSFFLAGS: Try again''. (2) The driver
reports eth0
error messages (viewed by dmesg | more
)
or strange inconsistencies for each time it tries to send or
receive data. (3) Typing cat /proc/net/dev
shows
non-zero numbers in one of the errs, drop, fifo, frame or
carrier columns for eth0
. (4) Typing
cat /proc/interrupts
shows a zero interrupt count
for the card.
Most of the typical hardware configuration errors are also
discussed in the FAQ section.
Well, if you have got to this point and things still
aren't working, read the FAQ section
of this document, read the vendor specific section detailing
your particular card, and if it still doesn't work then
you may have to resort to posting to an appropriate
newsgroup for help. If you do post, please detail all
relevant information in that post, such as the card brand,
the kernel version, the driver boot messages, the output
from cat /proc/net/dev
, a clear description of
the problem, and of course what you
have already tried to do in an effort to get things to work.
You would be surprised at how many people post useless things like ``Can someone help me? My ethernet doesn't work.'' and nothing else. Readers of the newsgroups tend to ignore such silly posts, whereas a detailed and informational problem description may allow a `linux-guru' to spot your problem right away. Of course the same holds true when e-mailing a problem report - always provide as much information as possible.
The twisted pair cables, with the RJ-45 (giant phone jack) connectors is technically called 10BaseT. You may also hear it called UTP (Unsheilded Twisted Pair).
The thinnet, or thin ethernet cabling, (RG-58 coaxial cable) with the BNC (metal push and turn-to-lock) connectors is technically called 10Base2.
The older thick ethernet (10mm coaxial cable) which is only found in older installations is called 10Base5. The 15 pin D-shaped plug found on some ethernet cards (the AUI connector) is used to connect to thick ethernet and external transcievers.
Most ethercards also come in a `Combo' version for only $10-$20 more. These have both twisted pair and thinnet transceiver built-in, allowing you to change your mind later.
Most installations will use 10BaseT/100BaseT 10Base2 does not offer any upgrade path to 100Base-whatever. 10Base2 is fine for hobbyists setting up a home network when purchasing a hub is not desireable for some reason or another.
See Cables, Coax... for other concerns with different types of ethernet cable.
Hosting by: Hurra Communications Ltd.
Generated: 2007-01-26 17:58:17