[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#294303: hotplug: Bad NET invocation: $INTERFACE is not set



On Thu, Feb 24, 2005 at 10:10:45AM +0100, Marco d'Itri wrote:
> On Feb 24, Horms <horms@verge.net.au> wrote:
> 
> > udev names tun net/tun, and as it now thinks it is a net device, calls
> > hotplug tun 
> What makes you think that udev calls hotplug? This is not how I know it
> works.

This makes me suspicious.

$ dpkg -S /etc/dev.d/net/hotplug.dev
udev: /etc/dev.d/net/hotplug.dev
$ cat /etc/dev.d/net/hotplug.dev
#!/bin/sh
#
# Script to ensure that any network device that udev renames
# still gets the hotplug script run with the proper name.
#
# Released under the GPL v2
#
# Copyright (C) 2004 Greg Kroah-Hartman <greg@kroah.com>
#

# Do nothing if udev handles hotplug.d.
if [ "$MANAGED_EVENT" == "1" ]; then
	exit 0
fi

# ok, we have renamed this device, so let the network hotplug script
# know about it to setup the device properly...
if [ -f /etc/hotplug.d/default/default.hotplug ]; then
	exec /etc/hotplug.d/default/default.hotplug net
fi

> > In udev thinking tun is a net device?
> I don't think so, see the difference between the two events logged at
> hotplug level:

I think that the second one is caused by hotplug being
executed by udev as per the script above.

> /etc/hotplug.d/default/logger.hotplug misc
> 
> ACTION='add'
> DEVPATH='/class/misc/net/tun'
> SEQNUM='194'
> 
> /etc/hotplug.d/default/logger.hotplug net
> 
> ACTION='add'
> DEVPATH='/class/net/tap0'
> INTERFACE='tap0'
> SEQNUM='195'

-- 
Horms



Reply to: