|
|
712866 |
From 4c2d48d5c4449789018024c3d9f402f5108e9a68 Mon Sep 17 00:00:00 2001
|
|
|
712866 |
From: Harald Hoyer <harald@redhat.com>
|
|
|
712866 |
Date: Mon, 31 Mar 2014 16:21:49 +0200
|
|
|
712866 |
Subject: [PATCH] fcoe: workaround fcoe timing issues
|
|
|
712866 |
|
|
|
712866 |
---
|
|
|
712866 |
modules.d/95fcoe/fcoe-genrules.sh | 2 +-
|
|
|
712866 |
modules.d/95fcoe/fcoe-up.sh | 23 ++++++++++++++++++++---
|
|
|
712866 |
2 files changed, 21 insertions(+), 4 deletions(-)
|
|
|
712866 |
|
|
|
712866 |
diff --git a/modules.d/95fcoe/fcoe-genrules.sh b/modules.d/95fcoe/fcoe-genrules.sh
|
|
|
5c6c2a |
index 80894ed2..fa3af6df 100755
|
|
|
712866 |
--- a/modules.d/95fcoe/fcoe-genrules.sh
|
|
|
712866 |
+++ b/modules.d/95fcoe/fcoe-genrules.sh
|
|
|
712866 |
@@ -13,4 +13,4 @@
|
|
|
712866 |
else
|
|
|
712866 |
printf 'ACTION=="add", SUBSYSTEM=="net", NAME=="%s", RUN+="/sbin/initqueue --onetime --unique --name fcoe-up-$env{INTERFACE} /sbin/fcoe-up $env{INTERFACE} %s"\n' "$fcoe_interface" "$fcoe_dcb"
|
|
|
712866 |
fi
|
|
|
712866 |
-} > /etc/udev/rules.d/92-fcoe.rules
|
|
|
712866 |
+} >> /etc/udev/rules.d/92-fcoe.rules
|
|
|
712866 |
diff --git a/modules.d/95fcoe/fcoe-up.sh b/modules.d/95fcoe/fcoe-up.sh
|
|
|
5c6c2a |
index 60642cfd..edbfcc84 100755
|
|
|
712866 |
--- a/modules.d/95fcoe/fcoe-up.sh
|
|
|
712866 |
+++ b/modules.d/95fcoe/fcoe-up.sh
|
|
|
712866 |
@@ -39,10 +39,27 @@ if [ "$dcb" = "dcb" ]; then
|
|
|
712866 |
sleep 1
|
|
|
712866 |
i=$(($i+1))
|
|
|
712866 |
done
|
|
|
712866 |
- dcbtool sc "$netif" dcb on
|
|
|
712866 |
- sleep 1
|
|
|
712866 |
- dcbtool sc "$netif" app:fcoe e:1 a:1 w:1
|
|
|
712866 |
+
|
|
|
712866 |
+ # on some systems lldpad needs some time
|
|
|
712866 |
+ # sleep until we find a better solution
|
|
|
712866 |
+ sleep 30
|
|
|
712866 |
+
|
|
|
712866 |
+ while [ $i -lt 60 ]; do
|
|
|
712866 |
+ dcbtool sc "$netif" dcb on && break
|
|
|
712866 |
+ info "Retrying to turn dcb on"
|
|
|
712866 |
+ sleep 1
|
|
|
712866 |
+ i=$(($i+1))
|
|
|
712866 |
+ done
|
|
|
712866 |
+
|
|
|
712866 |
+ while [ $i -lt 60 ]; do
|
|
|
712866 |
+ dcbtool sc "$netif" app:fcoe e:1 a:1 w:1 && break
|
|
|
712866 |
+ info "Retrying to turn fcoe on"
|
|
|
712866 |
+ sleep 1
|
|
|
712866 |
+ i=$(($i+1))
|
|
|
712866 |
+ done
|
|
|
712866 |
+
|
|
|
712866 |
sleep 1
|
|
|
712866 |
+
|
|
|
712866 |
fipvlan "$netif" -c -s
|
|
|
712866 |
elif [ "$netdriver" = "bnx2x" ]; then
|
|
|
712866 |
# If driver is bnx2x, do not use /sys/module/fcoe/parameters/create but fipvlan
|