HD-Install The right way to Fix Static Net ConfigForum: Other Help Topics Topic: HD-Install The right way to Fix Static Net Config started by: longship Posted by longship on Dec. 08 2004,20:46
If you don't run DHCP and you need a static network configuration the HD install can be frustrating. After every boot you have to reenable your network configuration. This article shows how to fix this problem so that you can configure your network the Un*x way and have the DSL scripts respect that configuration.The general procedure is to first modify the DSL boot and shutdown scripts to respect the standard Linux network configuration files. Second, add the nodhcp parameter to Lilo boot parameters. Finally, configure your network interfaces and reboot. Before doing these steps make sure that you are root. Bring up a terminal and enter the following:
Step 1 - Modify DSL scripts in /etc/init.d 1. Edit /etc/init.d/knoppix-autoconfig to bring up network interfaces. Near line 800, find the code that looks like this: (Search for "nodhcp")
Delete the "...blah, blah, blah..." part and add the following code after the echo... line but before the else line:
This code parses the ethx interfaces out of the /etc/network/interfaces file and brings those interfaces up using ifup. N.B., Do not use ifconfig to bring up interfaces! 2. Edit /etc/init.d/knoppix-halt and /etc/init.d/knoppix-reboot to shut down the network properly. In both files: Replace:
with:
Step 2 - Add nodhcp to lilo.conf. Edit the file /etc/lilo.conf Find the line that reads append="blah blah blah" Add nodhcp to the statement within the quote marks. E.G., it should now read:
Save the file. Run the lilo program. From the command line enter:
It you made the correct change, it should update the boot record and reinstall lilo. Step 3 - Modify /etc/network/interfaces The DSL script netcardconfig will add the necessary ethx interface to /etc/network/interfaces for you. Either run this script or modify the file manually. If you don't know how to do this Google is your friend. Note that my fix allows you to put in as many ethx interfaces as you need. That's it! When you reboot your network cards should be brought up just like they're supposed to. Just as important, shutting down, or rebooting should shut them down. |