tags 468896 patch
thanks
Followup-For: Bug #468896
Package: ifplugd
Version: 0.28-11
-- Package-specific info:
/proc/net/dev interfaces:
lo
eth0
eth1
-- System Information:
Debian Release: lenny/sid
APT prefers unstable
APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)
Kernel: Linux 2.6.25-7.slh.1-sidux-686 (SMP w/1 CPU core; PREEMPT)
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages ifplugd depends on:
ii debconf [debconf-2.0] 1.5.22 Debian configuration management sy
ii libc6 2.7-12 GNU C Library: Shared libraries
ii libdaemon0 0.12-2 lightweight C library for daemons
Versions of packages ifplugd recommends:
ii ifupdown 0.6.8+nmu1 high level tools to configure netw
-- debconf information:
* ifplugd/interfaces:
* ifplugd/hotplug_interfaces: eth0
* ifplugd/args: -q -f -u0 -d10 -I
* ifplugd/suspend_action: stop
Invent a very basic "allow-ifplugd" interfaces(5) class.
The ifplugd udev agent can read /etc/network/interfaces for interfaces
indicated to operate under the "allow-ifplugd" class, thus allowing one to have
ifplugd start, and create meaningful network connections, via ifupdown
configuration alone, without having to list interface in HOTPLUG_INTERFACES of
/etc/default/ifplugd.
A simple /etc/network/interfaces looks like:
allow-ifplugd eth0
iface eth0 inet dhcp
I find this mode of operation very appealing; with sane ifplugd defaults, only
one config file must be edited to activate plug detection + networking.
The following patch applies on top of the patch sent to #325614 that makes
the ifplugd udev agent script more robust.
Thanks, Kel.
---
--- a/debian/ifplugd.udev.agent
+++ b/debian/ifplugd.udev.agent
@@ -87,4 +87,10 @@
fi
}
+# Invent an "allow-ifplugd" interfaces class
+ALLOW_HOTPLUG_INTERFACES="$(sed -n -e
"s|^allow-${DAEMON_NAME}[[:space:]]\+||p" \
+ /etc/network/interfaces 2>/dev/null || true)"
+# Append allow-ifplugd interfaces to statically listed interface list
+HOTPLUG_INTERFACES="$HOTPLUG_INTERFACES $ALLOW_HOTPLUG_INTERFACES"
+
ifplugd_daemon &
---
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]