28 lines
967 B
Diff
28 lines
967 B
Diff
|
From 4f122cd0cf46c1fdc1badb22049607a6abf0c885 Mon Sep 17 00:00:00 2001
|
||
|
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
|
||
|
Date: Mon, 4 Feb 2019 17:04:59 +0100
|
||
|
Subject: [PATCH] LVM-activate: only check locking_type when LVM < v2.03
|
||
|
|
||
|
---
|
||
|
heartbeat/LVM-activate | 7 ++++++-
|
||
|
1 file changed, 6 insertions(+), 1 deletion(-)
|
||
|
|
||
|
diff --git a/heartbeat/LVM-activate b/heartbeat/LVM-activate
|
||
|
index c2239d881..3c462c75c 100755
|
||
|
--- a/heartbeat/LVM-activate
|
||
|
+++ b/heartbeat/LVM-activate
|
||
|
@@ -311,7 +311,12 @@ config_verify()
|
||
|
lvmlockd_check()
|
||
|
{
|
||
|
config_verify "global/use_lvmlockd" "1"
|
||
|
- config_verify "global/locking_type" "1"
|
||
|
+
|
||
|
+ # locking_type was removed from config in v2.03
|
||
|
+ ocf_version_cmp "$(lvmconfig --version | awk '/LVM ver/ {sub(/\(.*/, "", $3); print $3}')" "2.03"
|
||
|
+ if [ "$?" -eq 0 ]; then
|
||
|
+ config_verify "global/locking_type" "1"
|
||
|
+ fi
|
||
|
|
||
|
# We recommend to activate one LV at a time so that this specific volume
|
||
|
# binds to a proper filesystem to protect the data
|