summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStéphane Graber <stgraber@ubuntu.com>2012-01-20 19:13:23 -0500
committerAndrew Shadura <andrew.shadura@collabora.co.uk>2017-11-26 10:50:06 +0000
commit3307aa6f852cd13f9f50a704099b2bf19b6b9439 (patch)
tree55c5c5a21e044c770d4d58cafce34f4fa58670df
parent7517228145310a29b7cb7f4bddccb1b70df347eb (diff)
Run vconfig only when the interface doesn't already exist.
Now that a vlan interface can be created by a udev hook and ifupdown checks return codes from the scripts, make sure to properly deal with an already existing interface.
-rw-r--r--debian/changelog8
-rw-r--r--debian/network/if-pre-up.d/vlan2
2 files changed, 9 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index f7437f0..fc1c301 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+vlan (1.9-3.3) UNRELEASED; urgency=low
+
+ * Now that a vlan interface can be created by a udev hook and
+ ifupdown checks return codes from the scripts,
+ make sure to properly deal with an already existing interface.
+
+ -- Stéphane Graber <stgraber@ubuntu.com> Fri, 20 Jan 2012 19:13:23 -0500
+
vlan (1.9-3.2) unstable; urgency=medium
* Non-maintainer upload.
diff --git a/debian/network/if-pre-up.d/vlan b/debian/network/if-pre-up.d/vlan
index 1580fc2..1796988 100644
--- a/debian/network/if-pre-up.d/vlan
+++ b/debian/network/if-pre-up.d/vlan
@@ -49,7 +49,7 @@ case "$IFACE" in
;;
esac
-if [ -n "$IF_VLAN_RAW_DEVICE" ]; then
+if [ -n "$IF_VLAN_RAW_DEVICE" ] && [ ! -d /sys/class/net/$IFACE ]; then
if [ ! -x /sbin/vconfig ]; then
exit 0
fi