Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP1:GA
drbd-utils.9951
skip_sh-b-pri_in_v9.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File skip_sh-b-pri_in_v9.patch of Package drbd-utils.9951
diff -Naur drbd-utils-9.0.0.orig/scripts/drbd drbd-utils-9.0.0/scripts/drbd --- drbd-utils-9.0.0.orig/scripts/drbd 2017-10-16 17:02:55.707528280 +0800 +++ drbd-utils-9.0.0/scripts/drbd 2017-10-16 17:34:02.134427141 +0800 @@ -55,6 +55,13 @@ . /lib/lsb/init-functions fi +local DRBD_VERSION DRBD_IS_V9=false +DRBD_VERSION="$($DRBDADM --version 2>/dev/null | grep DRBD_KERNEL_VERSION_CODE | cut -d '=' -f 2)" +if (( $DRBD_VERSION >= 0x090000 )) +then + DRBD_IS_V9=true +fi + assure_module_is_loaded() { [ -e "$PROC_DRBD" ] && return @@ -191,7 +198,8 @@ # Become primary if configured # Currently, this is necessary for drbd8 # drbd9 supports automatic promote and removes the "sh-b-pri" command. - $DRBDADM sh-b-pri all || true + # Do not run "$DRBDADM sh-b-pri all" in v8 + $DRBD_IS_V9 || $DRBDADM sh-b-pri all || true log_end_msg 0 # Now handle stacked devices, if any @@ -218,7 +226,7 @@ done done $DRBDADM -S wait-con-int # User interruptible version of wait-connect all - $DRBDADM -S sh-b-pri all || true + $DRBD_IS_V9 || $DRBDADM -S sh-b-pri all || true log_end_msg 0 fi fi
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor