[ewg] [PATCH 2/2] IB/iser: Ask the user to stop open-iscsi before stopping openibd on RH4

Erez Zilber erezz at voltaire.com
Thu Apr 10 07:49:44 PDT 2008


In RedHat 4, some OFED kernel modules (including open-iscsi modules)
use symbols that are encapsulated in ib_core (e.g. kfifo). ib_core
may not be unloaded before open-iscsi is unloaded. Therefore, disconnecting
from open-iscsi over iSER sessions is not suffiecient if the user tries to
stop openibd. The user must be prompted to stop open-iscsi before stopping
openibd.

Signed-off-by: Erez Zilber <erezz at voltaire.com>
---
 ofed_scripts/ofa_kernel.spec |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/ofed_scripts/ofa_kernel.spec b/ofed_scripts/ofa_kernel.spec
index eed2484..01411e7 100755
--- a/ofed_scripts/ofa_kernel.spec
+++ b/ofed_scripts/ofa_kernel.spec
@@ -455,6 +455,13 @@ if [ -f /etc/SuSE-release ]; then
         fi
 fi
 
+# If it's RH4, open-iscsi must be stopped before openibd
+if [[ -f /etc/redhat-release && $(grep -c "Red Hat Enterprise Linux AS release 4" /etc/redhat-release) -eq 1 ]]; then
+    cat /etc/init.d/openibd | sed -e 's/Please logout from all open-iscsi over iSER sessions/Please stop open-iscsi: \/etc\/init.d\/iscsi stop/' > /etc/init.d/openibd.$$
+    mv /etc/init.d/openibd.$$ /etc/init.d/openibd
+    chmod +x /etc/init.d/openibd
+fi
+
 %if %{build_kernel_ib}
     echo >> %{IB_CONF_DIR}/openib.conf
     echo "# Load UCM module" >> %{IB_CONF_DIR}/openib.conf
-- 
1.5.4.4





More information about the ewg mailing list