having a hell of a time getting onboard LAN (Abit IS7) going under Slackware

Booty

Senior member
Aug 4, 2000
977
0
0
I downloaded the driver from 3com (which was on the CD as well) and followed the instructions, which were:


---------------------------------------------------------
1) Make sure that the kernel source is installed in /usr/src/linux
or /usr/src/linux-2.4.

2) Copy the file /Linux/3c2000.tar.gz from the 3Com driver CD to
your hard drive.

3) Change to the directory containing 3c2000.tar.gz

4) Type 'tar zxvf 3c2000.tar.gz'

5) Type 'cd 3c2000'

Note: on SuSE systems since 7.1, you will have to execute the
following commands before running make:

cp /boot/vmlinuz.version.h /usr/src/linux/include/linux/version.h
cp /boot/vmlinuz.autoconf.h /usr/src/linux/include/linux/autoconf.h

For more details se http://sdb.suse.de/en/sdb/html/mwalter_kernel_24.html

6) Type 'make load' to load the driver.

Alternatively, you may type the following to load the driver:

insmod 3c2000.o

Something like the following will be added to /var/log/messages:

Jan 22 19:31:19 localhost kernel: 3C2000: 3Com Gigabit NIC Driver Version A08
Jan 22 19:31:19 localhost kernel: Copyright (C) 2003 3Com Corporation.
Jan 22 19:31:19 localhost kernel: Copyright (C) 2003 Marvell.
Jan 22 19:31:19 localhost kernel: eth0: 3Com Gigabit NIC (3C2000)

Depending on your configuration, the OS may then automatically bring the
interface up and request an address from a DHCP server. If it does not,
bring the interface up with the command:

ifconfig eth0 up

You may have to substitue 'eth0' for your actual interface if you have
more than one ethernet NIC installed.

If your system is not configured for DHCP, you can assign an IP address
with the command:

ifconfig eth0 a.b.c.d

Where a.b.c.d is the IP address that you wish to use. Again, eth0 may
be different depending on your system configuration.
-------------------------------------------------------------------------------------------------

Well, that all works fine, but I've been unable to get an IP, for starters. Secondly, I have to re-load the module manually every time I boot. I did a 'make install' instead of a 'make load' so that the module was copied where it needed to be, and I read while searching the 'net that 'modprobe' was the better way to load the module, but I can't seem to get it to find the module (3c2000.o).

Anyway, what this all boils down to is that I'm still pretty much a newbie and am in a little over my head I suppose. I'm dual-booting Slackware 9 and Windows 2000 on this machine, and all of that is actually installed fine... I'm just trying to get Slackware configured and am a little lost with the network configuration (haven't even started trying to tackle the sound yet).

Where do I need to copy this module to so that I can load it at boot time? What file(s) do I need to edit to do so? How do I enable DHCP after all that? I'm doing my best to sort through information on the 'net, but in the meantime any help at all would be greatly appreciated. Thanks.


 

drag

Elite Member
Jul 4, 2002
8,708
0
0
first off you modules are located in /lib/modules/(kernel-name)

to find it just use a simple bash one-liner,

du -a /lib/modules | grep 3c2

du shows folders and their paths and sizes, the -a tells it to include files, too, the pipe "|" pipes the output into another tool called grep. This guy will only show lines that include the text string indicated.

So you take to commands, hook them up and make one simple search program. I use it all the time. I even add 2>/dev/null to it. Look that stuff up in a beginning bash howto search in google. ;)


Alright. SLackware uses a unusual startup script for linux. They use the better BSD-style scripts rather then the too-complicated/much-work System V style scripts that everybody else uses.

If you want something to happen in start up you have to play with the init scripts. Each runlevel is for a different purpose...

So in BSD-style script it usually something like, each main runlevel script has a bunch of lines like:

if this secondary script exists,
execute that secondary script
fi

to hook it up to each little script.

The best way to learn what happens is to visit slackware, read thru that, and then add little
echo "wowsers!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1111"
type lines to the init scripts so that when it boots up you can see what part of the init scripts do what. Also examine all the /etc/ files with inittab-like names and any folders or files beginning in "rc."

Now to avoid all that messing around you have a handy dandy little program called netconfig. This will configure your network for you, but I don't know if it will make the module load up at boot up.... You may need to add a line to rc.modules to get it to load automaticly. Not sure.

To manually configure your network (if you like doing stuff the hardway or netconfig fails in some manner) you can run something like

dhcpcd eth0

that will call on the dhcp server to give you a configuration. Or sometimes it's dhclient instead of dhcpcd, I don't remember for slackware... may even be something weird like pump.

To pass all the arguments yourself you can after the modules are loaded...
(substitute your ip addresses accordingly)

ifconfig eth0 you.ip.address
route add default gw your.gateway.ip.address

The after the dhcpd stuff of ifconfigure stuff all you have to do is make sure that a file /etc/resolv.conf exists and has a line (or as many as you'd like) that have your dns server's address in it.
The line has to be something like:

nameserver your.dns.server's.ip.address


Remember if you have a question about the sytax of the commands or something like that, check out their man files. Like:

man ifconfig


 

cleverhandle

Diamond Member
Dec 17, 2001
3,566
3
81
Let's trim that down a little...

1) Copy the module to /lib/modules/2.4.XX/kernel/drivers/net. (Substitute for XX appropriately - probably 20 or 21.)
2) Add a line modprobe 3c2000 to /etc/rc.d/rc.modules.
3) Reboot. You should see eth0 listed in the output of ifconfig -a.
4) IIRC, the main Slackware config tool is setup. It should have a section for NIC configuration.
 

drag

Elite Member
Jul 4, 2002
8,708
0
0
Originally posted by: cleverhandle
Let's trim that down a little...

1) Copy the module to /lib/modules/2.4.XX/kernel/drivers/net. (Substitute for XX appropriately - probably 20 or 21.)
2) Add a line modprobe 3c2000 to /etc/rc.d/rc.modules.
3) Reboot. You should see eth0 listed in the output of ifconfig -a.
4) IIRC, the main Slackware config tool is setup. It should have a section for NIC configuration.

feed a man a fish, and he has food for a day. Teach a man to fish, and he has food for a lifetime. ;)

 

Booty

Senior member
Aug 4, 2000
977
0
0
Thanks for the excellent replies guys... here's the one nagging problem... I copied the module to that directory, but modprobe doesn't find it. Any ideas why this might be?
 

cleverhandle

Diamond Member
Dec 17, 2001
3,566
3
81
Try doing a depmod -a. I'm not sure if that's really necessary, though. If it doesn't work, then you probably put the module in the wrong directory.
 

Booty

Senior member
Aug 4, 2000
977
0
0
all appears to be well now... modprobe worked, then had to run ifconfig eth0 up and then dhcpcd. Gonna try to have it connect on startup now, so hopefully that all goes just as smoothly, but we're making progress. Thanks as always for all the helpful replies... this is by far the best forum on Anandtech IMO.

//Edit - While I'm here... any suggestions on what module (and/or anything else) I need to configure to get my sound up? :)