My experiences of setting up a network may be of some use to others.
Installing a Netgear FA311 10/100MBps pci.
This came with a driver: fa311.o and fa311.c. This is apparently for
Slackware 3.6. I have a system based on Slackware 3.3 and was unable to
compile the source or insmod the supplied object file.
I obtain natsemi.c, pci-scan.c and pci-scan.h from www.scyld.com (thanks
Donald Becker). I had some trouble compiling because of a bad
/usr/src/linux-2.0.30/include/asm-i386/string.h (some assembler version of
a memcpy() would not compile).
I hacked and used /usr/src/linux-2.0.30/include/asm-i386/string-486.h to
get the modules compiled.
Moved pci-scan.o and natsemi.o to /lib/modules/2.0.30/net/.
Played with depmod, insmod, lsmod, rmmod, ifconfig and route until I got
things working. Then:
Setup /etc/rc.d/rc.inet1
------------------------
HOSTNAME=`cat /etc/HOSTNAME`
# Attach the loopback device.
/sbin/ifconfig lo 127.0.0.1
/sbin/route add -net 127.0.0.0 # netmask 255.0.0.0 lo
/sbin/ifconfig dummy $HOSTNAME
/sbin/route add -host $HOSTNAME
# Edit for your setup.
IPADDR="192.168.0.1" # REPLACE with YOUR IP address!
NETMASK="255.255.255.0" # REPLACE with YOUR netmask!
NETWORK="192.168.0.0" # REPLACE with YOUR network address!
BROADCAST="192.168.0.255" # REPLACE with YOUR broadcast address, if you
# have one. If not, leave blank and edit below.
#GATEWAY="" # REPLACE with YOUR gateway address!
# Uncomment the line below to initialize the ethernet device.
/sbin/ifconfig eth0 ${IPADDR} broadcast ${BROADCAST} netmask ${NETMASK}
# Uncomment these to set up your IP routing table.
/sbin/route add -net ${NETWORK} netmask ${NETMASK} eth0
#/sbin/route add default gw ${GATEWAY} netmask 0.0.0.0 metric 1
Added to /etc/rc.d/rc.modules
-----------------------------
/sbin/modprobe natsemi
Added to /etc/hosts
-------------------
# For loopbacking.
127.0.0.1 localhost loopback
# This network.
192.168.0.1 zeus
# Since there is only one other machine we put it here.
192.168.0.2 clio
Added to /etc/hosts.allow
-------------------------
ALL EXCEPT PARANOID: 192.168.0.
Rebooted machine.
Problems
--------
On boot up the IRQs are allocated as follows:
14 ide
11 serial
10 display
9 mass storage
11 ethernet
The collision on 11 appears to be a shared interrupt but we get:
SIOCSIFADDR: No such device.
SIOCADDRT: Network unreachable.
Just after modprobe has correctly identified the devices.
However the network works.
Now we see
----------
hadron:/home/bob# ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Bcast:127.255.255.255 Mask:255.0.0.0
UP BROADCAST LOOPBACK RUNNING MTU:3584 Metric:1
RX packets:43 errors:0 dropped:0 overruns:0 frame:0
TX packets:43 errors:0 dropped:0 overruns:0 carrier:0 coll:0
eth0 Link encap:Ethernet HWaddr 00:02:E3:04:2A:D6
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:13977 errors:0 dropped:0 overruns:0 frame:0
TX packets:13928 errors:0 dropped:0 overruns:0 carrier:0 coll:0
Interrupt:11 Base address:0xe000
hadron:/home/bob# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.0.0 * 255.255.255.0 U 0 0 3 eth0
loopback * 255.0.0.0 U 0 0 1 lo
Well that looks really simple but it took me most of the weekend to get
this far. Looking back I wonder why it was so difficult.
The other machine is an old 486 machine and I installed another card. One
problem was that this card came with some diagnostic program and I wasted
some time trying to get the diagnostic program to communicate with the
other machine. This turned out to be a total waste of time and in fact I
never did get any sense out of it (the program).
Anyway second machine, fitting a Netgear EA201 ISA 10MBps card.
I obtained ne2.c from www.scyld.com but could not get this to compile. The
486 has some old Slackware version installed but a 2.0.30 kernel. As it
happened the ne.o plus 8390.o in /lib/modules/2.0.30/net/ did the trick.
Played with depmod, insmod, lsmod, rmmod, ifconfig and route until I got
things working. Then:
Board setup
-----------
Run the setup program under DOS. Switch of PnP and save in EEPROM. Note
address and IRQ from the setup program.
Setup /etc/rc.d/rc.local
------------------------
There is not a /etc/rc.d/rc.inet1
HOSTNAME=`cat /etc/HOSTNAME`
# Attach the loopback device.
/sbin/ifconfig lo 127.0.0.2
/sbin/route add -net 127.0.0.0 # netmask 255.0.0.0 lo
/sbin/ifconfig dummy $HOSTNAME
/sbin/route add -host $HOSTNAME
# Edit for your setup.
IPADDR="192.168.0.2" # REPLACE with YOUR IP address!
NETMASK="255.255.255.0" # REPLACE with YOUR netmask!
NETWORK="192.168.0.0" # REPLACE with YOUR network address!
BROADCAST="192.168.0.255" # REPLACE with YOUR broadcast address, if you
# have one. If not, leave blank and edit below.
#GATEWAY="" # REPLACE with YOUR gateway address!
# Uncomment the line below to initialize the ethernet device.
/sbin/ifconfig eth0 ${IPADDR} broadcast ${BROADCAST} netmask ${NETMASK}
# Uncomment these to set up your IP routing table.
/sbin/route add -net ${NETWORK} netmask ${NETMASK} eth0
#/sbin/route add default gw ${GATEWAY} netmask 0.0.0.0 metric 1
Added to /etc/rc.d/rc.modules
-----------------------------
This requires an io address to be given.
/sbin/modprobe ne io=0x300
Added to /etc/hosts
-------------------
# For loopbacking.
127.0.0.1 localhost
192.168.0.2 clio
# Since there is only one other machine we put it here.
192.168.0.1 zeus
Added to /etc/hosts.allow
-------------------------
ALL EXCEPT PARANOID: 192.168.0.
Rebooted machine.
Now we see
----------
clio:/home/bob# ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.2 Bcast:127.255.255.255 Mask:255.0.0.0
UP BROADCAST LOOPBACK RUNNING MTU:3584 Metric:1
RX packets:16 errors:0 dropped:0 overruns:0 frame:0
TX packets:16 errors:0 dropped:0 overruns:0 carrier:0 coll:0
eth0 Link encap:Ethernet HWaddr 00:40:05:AA:3D:E2
inet addr:192.168.0.2 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:14360 errors:0 dropped:0 overruns:0 frame:0
TX packets:14274 errors:0 dropped:0 overruns:0 carrier:0 coll:0
Interrupt:3 Base address:0x300
clio:/home/bob# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.0.0 * 255.255.255.0 U 0 0 2 eth0
127.0.0.0 * 255.0.0.0 U 0 0 6 lo
I must have learnt something from setting up the first machine because the
second one was done in an hour or so. Most of the time was taken up in
sneaker netting things like ifconfig and route onto the machine.
I was really pleased when I could ping one machine from the other. Then I
had to ftp inetd and friends onto the old machaine and set that up so that
I could make the connection either way.
Then came a few hours testing. Connecting in varios modes, soft booting
and power cycling to make sure everything comes up right. Checking cables
can be disconnected and connected without problems.
I used a hub for this set up with expansion in mind, although I could have
used a crossover cable. However one really useful feature is that the
activity lights are in easy view.
I hope this gives some help and encouragement to others.
--
Bob