File 0011-Test-if-scripts-used-in-77-network.rules-exists.patch of Package sysconfig.openSUSE_12.1_Update
From 032c457bf1adff3968c4f371b78db638a05c0f17 Mon Sep 17 00:00:00 2001
From: Marius Tomaschewski <mt@suse.com>
Date: Wed, 14 Mar 2012 13:21:53 +0100
Subject: [PATCH] Test if scripts used in 77-network.rules exists
Added tests to the 77-network.rules rule file if the /sbin/ifup
and /etc/sysconfig/network/scripts/ifup-sysctl exist (bnc#724775).
Also disabled the IMO obsolete ipw3945d.sh script run completely.
Signed-off-by: Marius Tomaschewski <mt@suse.com>
---
config/77-network.rules | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/config/77-network.rules b/config/77-network.rules
index f86a8e3..56b7927 100644
--- a/config/77-network.rules
+++ b/config/77-network.rules
@@ -1,11 +1,12 @@
# Driver module ipw3945 requires an userspace daemon to register network
-# interfaces.
-SUBSYSTEM=="drivers", ACTION=="add", DEVPATH=="/bus/pci/drivers/ipw3945", RUN+="ipw3945d.sh"
+# interfaces.
+# Commented it out -- looks like something old & obsolete.
+#SUBSYSTEM=="drivers", ACTION=="add", DEVPATH=="/bus/pci/drivers/ipw3945", TEST=="ipw3945d.sh", RUN+="ipw3945d.sh"
#
# Apply per interface sysctl settings before setup (see man 5 ifsysctl):
#
-SUBSYSTEM=="net", ACTION=="add", RUN+="/etc/sysconfig/network/scripts/ifup-sysctl $env{INTERFACE} -o hotplug"
+SUBSYSTEM=="net", ACTION=="add", TEST=="/etc/sysconfig/network/scripts/ifup-sysctl", RUN+="/etc/sysconfig/network/scripts/ifup-sysctl $env{INTERFACE} -o hotplug"
#
# The following rules are to:
@@ -21,6 +22,7 @@ SUBSYSTEM=="net", ACTION=="add", RUN+="/etc/sysconfig/network/scripts/ifup-sysct
# We do it here name based for the well known/default interface names,
# ifup makes it again by interface type to catch also custom names.
#
+SUBSYSTEM=="net", TEST!="/sbin/ifup", GOTO="skip_ifup"
SUBSYSTEM=="net", ENV{INTERFACE}=="lo*|dummy*|vif*.*|br*|bond*|vlan*|gre*|sit*|tap*|tun*|ipip*|ip6tnl*|ipsec*|ppp*|ippp*|isdn*|modem*|dsl*|plip*|irda*", GOTO="skip_ifup"
SUBSYSTEM=="net", ACTION=="add", RUN+="/sbin/ifup $env{INTERFACE} -o hotplug"
SUBSYSTEM=="net", ACTION=="remove", RUN+="/sbin/ifdown %k -o hotplug"
--
1.7.7