Erez Zilber wrote:
Vladimir Sokolovsky wrote:
Doron Shoham wrote:
Vladimir Sokolovsky wrote:
Doron Shoham wrote:
 iscsi service should start after openibd service.
 iscsi service should stop before openibd service.

Signed-off-by: Doron Shoham <[EMAIL PROTECTED]>
---
Hi Doron,
Why can't you just put in the /etc/init.d/iscsi:

# chkconfig: 2345 16 84
Why is openibd's start 15 and stop 85?
will it always be correct?
Because the network start is 10 and stop is 90.
This is correct for now...

And in the /etc/init.d/open-iscsi:
Required-Start: openibd

And then update ofa_kernel.spec to set
Required-Stop: open-iscsi
In case that iser was selected and OS is SuSE.
You are right.
I'll do it that way.

This will change about 5 lines of code instead of about 150 lines of
your patch.

Regards,
Vladimir
I'll make a new patch.

Thanks,
Doron

Tell me if you need help with ofa_kernel.spec.



open-iscsi depends on the openibd service.
If iSER is selected and the OS is SuSE, edit the openibd
init script and add open-iscsi to its Required-Stop.

Signed-off-by: Doron Shoham <[EMAIL PROTECTED]>
Signed-off-by: Erez Zilber <[EMAIL PROTECTED]>
---
 ofed_scripts/ofa_kernel.spec |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/ofed_scripts/ofa_kernel.spec b/ofed_scripts/ofa_kernel.spec
index 954dd0c..eed2484 100755
--- a/ofed_scripts/ofa_kernel.spec
+++ b/ofed_scripts/ofa_kernel.spec
@@ -428,12 +428,18 @@ perl -i -ne 'if ([EMAIL PROTECTED]/bin/bash@) {
 fi
if [ -f /etc/SuSE-release ]; then
-        perl -i -ne 'if ([EMAIL PROTECTED]/bin/bash@) {
+    local_fs='$local_fs'
+    network='$network'
+    openiscsi=''
+    %if %{build_iser}
+        openiscsi='open-iscsi'
+    %endif
+        perl -i -ne "if ([EMAIL PROTECTED]/bin/bash@) {
         print [EMAIL PROTECTED]/bin/bash
 ### BEGIN INIT INFO
 # Provides:       openibd
 # Required-Start: $local_fs $network
-# Required-Stop: opensmd
+# Required-Stop: opensmd $openiscsi
 # Default-Start:  2 3 5
 # Default-Stop: 0 1 2 6
 # Description:    Activates/Deactivates InfiniBand Driver to \
@@ -442,7 +448,7 @@ if [ -f /etc/SuSE-release ]; then
 @;
                  } else {
                      print;
-                 }' /etc/init.d/openibd
+                 }" /etc/init.d/openibd
if ! ( /sbin/insserv openibd > /dev/null 2>&1 ); then
                 true

Applied,

Regards,
Vladimir
_______________________________________________
ewg mailing list
ewg@lists.openfabrics.org
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ewg

Reply via email to