[ Note: For this bug to be 'grave', it would have to be unusable by most or all users, cause data loss, or introduce a security hole. I don't think it qualifies on any of these counts and should probably be downgraded to 'important', (I'll leave that to Oliver though). ]
On Sun, Mar 19, 2006 at 05:30:11PM +1000, Jonathan Hepburn muttered these words: [ ... ] > Output: > + DAEMON_NAME=ifplugd > + DAEMON=/usr/sbin/ifplugd > + CFG=/etc/default/ifplugd > + '[' -x /usr/sbin/ifplugd ']' > + HOTPLUGFUNCS=/lib/udev/hotplug.functions > + '[' -f /lib/udev/hotplug.functions ']' > + . /lib/udev/hotplug.functions > ++ FIRMWARE_DIRS='/lib/firmware /usr/local/lib/firmware > /usr/lib/hotplug/firmware' > ++ EVENTS_DIR=/dev/.events > ++ MODPROBE='/sbin/modprobe -s -q' > ++ PATH=/sbin:/bin:/usr/sbin:/usr/bin > ++ '[' -e /etc/default/hotplug ']' > ++ '[' -x /usr/bin/logger ']' > ++ LOGGER=/usr/bin/logger > ++ '[' -t 1 -a -z /usr/bin/logger ']' > ++ '[' '!' -e /dev/log ']' > ++ '[' -t 1 ']' > + DEBUG=yes > + export DEBUG > + '[' usb0 ']' > + '[' -f /etc/default/ifplugd ']' > + . /etc/default/ifplugd > ++ INTERFACES= > ++ HOTPLUG_INTERFACES=all > ++ ARGS='-q -f -u0 -d10 -w -I' > ++ SUSPEND_ACTION=stop > + '[' -x /sbin/ifrename -a -r /etc/iftab ']' > + case $ACTION in > + for IF in '$HOTPLUG_INTERFACES' > + '[' usb0 = all -o all = all ']' > + debug_mesg Invoking ifplugd for usb0 > + '[' -z yes -o yes = no ']' > + mesg Invoking ifplugd for usb0 > + echo Invoking ifplugd for usb0 > Invoking ifplugd for usb0 > + /usr/bin/logger -t 'ifplugd.hotplug[22172]' Invoking ifplugd for usb0 > + /etc/init.d/ifplugd start usb0 > Starting Network Interface Plugging Daemon: usb0. > + break > > ifplugd will now run, and will now automatically bring up usb0. > However, after closing the interface it will not re-start it. I'm not sure I understand. Are you saying that the behavior is what is expected after manually starting it, but after removing and readding the device it fails? > The relevant part of ifconfig will then look like this: > > usb0 Link encap:Ethernet HWaddr EE:C7:72:82:CE:8F > UP BROADCAST RUNNING MULTICAST MTU:1494 Metric:1 > RX packets:1 errors:0 dropped:0 overruns:0 frame:0 > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 txqueuelen:1000 > RX bytes:68 (68.0 b) TX bytes:0 (0.0 b) > > instead of like this: > > usb0 Link encap:Ethernet HWaddr EE:C7:72:82:CE:8F > inet addr:192.168.129.1 Bcast:192.168.129.255 Mask:255.255.255.0 > UP BROADCAST RUNNING MULTICAST MTU:1494 Metric:1 > RX packets:2 errors:0 dropped:0 overruns:0 frame:0 > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 txqueuelen:1000 > RX bytes:128 (128.0 b) TX bytes:0 (0.0 b) > > As you can see, the IP addresses specified in /etc/network/interfaces > have not been correctly re-assigned. In your configuration, the sequence of events should go roughly like the following: * When the usb device is attached, udev assigns it the name usb0 and runs /etc/hotplug.d/net/ifplugd.hotplug with ACTION=add. * /etc/hotplug.d/net/ifplugd.hotplug runs '/etc/init.d/ifplugd start usb0' and ifplugd is started on that interface. * If a link beat is detected, (you can run ifplugstatus to check this manually), "ifup usb0" is executed by ifplugd. When the device is detached, udev runs /etc/hotplug.d/net/ifplugd.hotplug with ACTION=remove, which in turn runs /etc/init.d/ifplugd stop usb0, and ifplugd is stopped for that interface. At this point, it appears that manual invocation of the scripts does in fact work, so perhaps udev is not kicking things off? What do the logs say immediately after adding and removing the device? You should be seeing something like .. Mar 12 12:37:22 aries ifplugd.hotplug[5561]: Invoking ifplugd for wlan0 Mar 12 12:46:48 aries ifplugd.hotplug[5777]: Stopping ifplugd for wlan0 -- Eric Evans [EMAIL PROTECTED]
signature.asc
Description: Digital signature