From mboxrd@z Thu Jan 1 00:00:00 1970 From: zephod Date: Mon, 14 Oct 2002 11:55:39 +0000 Subject: net.hotplug and ifup (Mandrake 9.0) Message-Id: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org Dear all, I have a setup with 5 network cards and I only start 2 of them at boot time (ON_BOOT=yes/no in the corresponding /etc/sysconfig/network-scripts/ifcfg-eth?). When I upgraded form Mandrake 8.2 to 9.0 the version of hotplug changed from 2002_01_14 to 2002_04_01. One of the differences is the following lines in net.agent (line 30): # Don't do anything if the network is stopped if [ ! -f /var/lock/subsys/network ]; then exit 0 fi With the removal of this piece of code all network interfaces are brought up by hotplug (using ifup) at boot time. Although I was tempted to reinsert these lines as a quick hack, I dove into the .etc directory to find some answers. After some digging I encountered some lines (47 in /sbin/ifup): if [ -n "$IN_HOTPLUG" -a "${HOTPLUG}" = "no" -o "${HOTPLUG}" = "NO" ] then exit 0 fi So I tried to set a "HOTPLUG=NO" in the interfaces I don't need at boot time. Offcourse now these interfaces are impossible to setup with e.g. ifup eth1. This was not the desired effect. The solution was to add "HOTPLUG=no" (notice the difference) to the corresponding /etc/sysconfig/network-scripts/ifcfg-eth? and add a line to /etc/hotplug/hotplpug.functions (line 21): export IN_HOTPLUG=yes which produces the result I need. I would like to see some comments about this. As far as I can see there are no other scripts (installed on my system) which use the IN_HOTPLUG variable. I suspect that it was intended to be used in this way. Can anyone confirm this? I checked out the latest version of hotplug (without installing it though) to see if the IN_HOTPLUG variable was set somewhere but couldn't find it. thanks, Z ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel