2016-06-07 15:51:45 +02:00
|
|
|
From e4a8408698ea1a4d77b1c6d9ba76a7eab93b024a Mon Sep 17 00:00:00 2001
|
2014-04-09 14:44:32 +02:00
|
|
|
From: Pawel Wieczorkiewicz <pwieczorkiewicz@suse.de>
|
|
|
|
Date: Tue, 8 Apr 2014 08:50:55 +0200
|
2016-06-07 15:51:45 +02:00
|
|
|
Subject: 40network: Fix race condition when wait for networks
|
2014-04-09 14:44:32 +02:00
|
|
|
|
|
|
|
If no network related params are specific, but rd.neednet=1 is set,
|
|
|
|
the default initqueue action is to wait until one of the network
|
|
|
|
interfaces is marked as setup properly.
|
|
|
|
|
|
|
|
This also help with initqueue's race condition when the network interface
|
|
|
|
shows upd late
|
|
|
|
|
|
|
|
References: bnc#866771
|
|
|
|
|
|
|
|
Signed-off-by: Hannes Reinecke <hare@suse.de>
|
|
|
|
---
|
|
|
|
modules.d/40network/net-genrules.sh | 3 +++
|
|
|
|
1 file changed, 3 insertions(+)
|
|
|
|
|
2016-06-07 15:51:45 +02:00
|
|
|
diff --git a/modules.d/40network/net-genrules.sh b/modules.d/40network/net-genrules.sh
|
|
|
|
index b1c156c..d591161 100755
|
|
|
|
--- a/modules.d/40network/net-genrules.sh
|
|
|
|
+++ b/modules.d/40network/net-genrules.sh
|
|
|
|
@@ -95,6 +95,9 @@ command -v fix_bootif >/dev/null || . /lib/net-lib.sh
|
2014-03-07 13:53:43 +01:00
|
|
|
cond='ACTION=="add", SUBSYSTEM=="net"'
|
|
|
|
# if you change the name of "91-default-net.rules", also change modules.d/80cms/cmssetup.sh
|
|
|
|
echo "$cond, $runcmd" > /etc/udev/rules.d/91-default-net.rules
|
|
|
|
+ if [ "$NEEDNET" = "1" ]; then
|
|
|
|
+ echo "[ -f /tmp/net.*.did-setup ]" >$hookdir/initqueue/finished/wait-network.sh
|
|
|
|
+ fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
# if you change the name of "90-net.rules", also change modules.d/80cms/cmssetup.sh
|
2016-06-07 15:51:45 +02:00
|
|
|
--
|
|
|
|
2.6.6
|
|
|
|
|