Saturday, July 02, 2005

Network

I have a very old NE ISA network card, which has never been detected automatically by any distribution. This was no exception.

To find the card is a simple case of loading the correct module. This could be done by "modprobe ne io=0x280 irq=10" to quickly test that it works, but since I want it to do this every time I boot, I simply uncommented the appropriate line in rc.modules (/sbin/modprobe ne io=0x280). This successfully loads the module, so it turns out that you don't actually need to specify the irq.

With the correct module loaded for the network card, some network stuff worked. For example I could ping other computers on my LAN, and even mount shared drives from them onto my box.

However I couldn't access the internet. My dad's WinXP box has a broadband modem and hence direct connection to the internet. This connection is shared, using Windows' helpful "Internet Connection Sharing" utility, which in theory should allow my computer to connect directly to the internet if I set that box as a gateway. Unfortunately this didn't work, giving "host not found" messages.

I started by rerunning netconfig, the tool used during installation to set up network connection. However I was pretty confident that everything was correct - a correct static IP address and subnet mask were right, gateway was set to the WinXP box's IP address, hostname isn't strictly important so I set it to "Tux" for want of anything better.

After much faffing around with different network tools and utilities and such, I found out that the problem was with the name server which I had given. The problem being that I hadn't given one. Turns out I need to answer yes to "Will you be accessing a name server" and give the IP address of the gateway computer when asked for the "Primary name server to use". Netconfig creates the file /etc/resolv.conf with this information, and once that was present and correct restarting the network stuff (rc.inet2 restart) made everything work correctly.