Blame SOURCES/LVM-activate-1-warn-vg_access_mode.patch

05afe3
From 12ef5a343158bbfaa5233468a0506074fceaac81 Mon Sep 17 00:00:00 2001
05afe3
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
05afe3
Date: Tue, 21 Aug 2018 12:14:49 +0200
05afe3
Subject: [PATCH] LVM-activate: return OCF_ERR_CONFIGURED for incorrect
05afe3
 vg_access_mode
05afe3
05afe3
---
05afe3
 heartbeat/LVM-activate | 7 +++----
05afe3
 1 file changed, 3 insertions(+), 4 deletions(-)
05afe3
05afe3
diff --git a/heartbeat/LVM-activate b/heartbeat/LVM-activate
05afe3
index fbd058288..55e36a2d2 100755
05afe3
--- a/heartbeat/LVM-activate
05afe3
+++ b/heartbeat/LVM-activate
05afe3
@@ -448,7 +448,7 @@ lvm_validate() {
05afe3
 		;;
05afe3
 	*)
05afe3
 		ocf_exit_reason "You specified an invalid value for vg_access_mode: $VG_access_mode"
05afe3
-		exit $OCF_ERR_ARGS
05afe3
+		exit $OCF_ERR_CONFIGURED
05afe3
 		;;
05afe3
 	esac
05afe3
 
05afe3
@@ -771,7 +771,6 @@ lvm_stop() {
05afe3
 		return $OCF_SUCCESS
05afe3
 	fi
05afe3
 
05afe3
-	lvm_validate
05afe3
 	ocf_log info "Deactivating ${vol}"
05afe3
 
05afe3
 	case ${VG_access_mode} in
05afe3
@@ -788,8 +787,8 @@ lvm_stop() {
05afe3
 		tagging_deactivate
05afe3
 		;;
05afe3
 	*)
05afe3
-		ocf_exit_reason "VG [${VG}] is not properly configured in cluster. It's unsafe!"
05afe3
-		exit $OCF_ERR_CONFIGURED
05afe3
+		ocf_log err "VG [${VG}] is not properly configured in cluster. It's unsafe!"
05afe3
+		exit $OCF_SUCCESS
05afe3
 		;;
05afe3
 	esac
05afe3