rebase resource-agents patch to CentOS 7.6 version

deduct Re-enable-background-execution-of-arp-commands.patch,
already in upgraded basecode

Test:
Pass build and simplex deploy test

Depends-On: https://review.openstack.org/629964/

Story: 2004522
Task: 28427

Change-Id: I6b5ab7f424cafd09164e55a64419f165357f2ffc
Signed-off-by: Martin, Chen <haochuan.z.chen@intel.com>
This commit is contained in:
Martin, Chen 2019-01-12 02:14:10 +08:00
parent 683d3632bc
commit 53d39bcee7
21 changed files with 285 additions and 342 deletions

View File

@ -1 +1 @@
TIS_PATCH_VER=12 TIS_PATCH_VER=0

View File

@ -11,13 +11,13 @@ diff --git a/SPECS/resource-agents.spec b/SPECS/resource-agents.spec
index 21fa049..fd8bc97 100644 index 21fa049..fd8bc97 100644
--- a/SPECS/resource-agents.spec --- a/SPECS/resource-agents.spec
+++ b/SPECS/resource-agents.spec +++ b/SPECS/resource-agents.spec
@@ -48,7 +48,7 @@ @@ -89,7 +89,7 @@
Name: resource-agents Name: resource-agents
Summary: Open Source HA Reusable Cluster Resource Scripts Summary: Open Source HA Reusable Cluster Resource Scripts
Version: 3.9.5 Version: 4.1.1
-Release: 124%{?dist} -Release: 12%{?dist}.7
+Release: 124.el7%{?_tis_dist}.%{tis_patch_ver} +Release: 12.el7_6.7%{?_tis_dist}.%{tis_patch_ver}
License: GPLv2+, LGPLv2+ and ASL 2.0 License: GPLv2+ and LGPLv2+ and ASL 2.0
URL: https://github.com/ClusterLabs/resource-agents URL: https://github.com/ClusterLabs/resource-agents
%if 0%{?fedora} || 0%{?centos_version} || 0%{?rhel} %if 0%{?fedora} || 0%{?centos_version} || 0%{?rhel}
-- --

View File

@ -20,7 +20,7 @@ index 2536cb7..e5fbbeb 100644
+%define debug_package %{nil} +%define debug_package %{nil}
+ +
%global upstream_prefix ClusterLabs-resource-agents %global upstream_prefix ClusterLabs-resource-agents
%global upstream_version 5434e96 %global upstream_version e711383f
-- --
1.8.3.1 1.8.3.1

View File

@ -12,7 +12,7 @@ diff --git a/SPECS/resource-agents.spec b/SPECS/resource-agents.spec
index ec85fc2..bb96485 100644 index ec85fc2..bb96485 100644
--- a/SPECS/resource-agents.spec --- a/SPECS/resource-agents.spec
+++ b/SPECS/resource-agents.spec +++ b/SPECS/resource-agents.spec
@@ -723,14 +723,11 @@ rm -rf %{buildroot} @@ -725,14 +725,11 @@ rm -rf %{buildroot}
%endif %endif
%if %{with linuxha} %if %{with linuxha}
@ -31,7 +31,7 @@ index ec85fc2..bb96485 100644
%if %{with rgmanager} %if %{with rgmanager}
/usr/lib/ocf/resource.d/redhat /usr/lib/ocf/resource.d/redhat
%endif %endif
@@ -753,8 +750,6 @@ rm -rf %{buildroot} @@ -758,8 +755,6 @@ rm -rf %{buildroot}
%{_includedir}/heartbeat %{_includedir}/heartbeat
@ -40,7 +40,7 @@ index ec85fc2..bb96485 100644
%{_mandir}/man7/*.7* %{_mandir}/man7/*.7*
### ###
@@ -864,7 +859,6 @@ rm -rf %{buildroot} @@ -912,7 +907,6 @@ rm -rf %{buildroot}
%exclude %{_mandir}/man8/ldirectord.8.gz %exclude %{_mandir}/man8/ldirectord.8.gz
# For compatability with pre-existing agents # For compatability with pre-existing agents

View File

@ -5,18 +5,18 @@ Subject: [PATCH] WRS: spec-include-TiS-patches.patch
Signed-off-by: zhipengl <zhipengs.liu@intel.com> Signed-off-by: zhipengl <zhipengs.liu@intel.com>
--- ---
SPECS/resource-agents.spec | 39 +++++++++++++++++++++++++++++++++++++++ SPECS/resource-agents.spec | 37 +++++++++++++++++++++++++++++++++++++
1 file changed, 39 insertions(+) 1 file changed, 37 insertions(+)
diff --git a/SPECS/resource-agents.spec b/SPECS/resource-agents.spec diff --git a/SPECS/resource-agents.spec b/SPECS/resource-agents.spec
index a16660a..ec85fc2 100644 index a16660a..ec85fc2 100644
--- a/SPECS/resource-agents.spec --- a/SPECS/resource-agents.spec
+++ b/SPECS/resource-agents.spec +++ b/SPECS/resource-agents.spec
@@ -263,6 +263,25 @@ Patch202: bz1536548-sap_redhat_cluster_connector-fix-unknown-gvi-function.patch @@ -148,6 +148,24 @@ Patch1002: bz1568588-9-google-cloud-sdk-oauth2client-python-rsa-to-cryptography.
Patch203: bz1543366-redis-add-support-for-tunneling-replication-traffic.patch Patch1003: bz1568588-10-gcloud-support-info.patch
Patch204: bz1546083-galera-fix-temp-logfile-rights.patch Patch1004: bz1568589-4-aliyun-vpc-move-ip-bundled.patch
+# WRS +# STX
+Patch1105: filesystem_rmon.patch +Patch1105: filesystem_rmon.patch
+Patch1106: new_ocf_return_codes.patch +Patch1106: new_ocf_return_codes.patch
+Patch1107: ipaddr2_check_if_state.patch +Patch1107: ipaddr2_check_if_state.patch
@ -32,17 +32,16 @@ index a16660a..ec85fc2 100644
+Patch1117: lvm_cleanup_refs_on_stop.patch +Patch1117: lvm_cleanup_refs_on_stop.patch
+Patch1118: ipaddr2_if_down.patch +Patch1118: ipaddr2_if_down.patch
+Patch1119: ipaddr2_ignore_lo_if_state.patch +Patch1119: ipaddr2_ignore_lo_if_state.patch
+Patch1120: Re-enable-background-execution-of-arp-commands.patch
+Patch1121: ipaddr2-avoid-failing-svc-if-down.patch +Patch1121: ipaddr2-avoid-failing-svc-if-down.patch
+Patch1122: ipaddr2-use-host-scope-for-addresses-on-loopback.patch +Patch1122: ipaddr2-use-host-scope-for-addresses-on-loopback.patch
Obsoletes: heartbeat-resources <= %{version} Obsoletes: heartbeat-resources <= %{version}
Provides: heartbeat-resources = %{version} Provides: heartbeat-resources = %{version}
@@ -582,6 +601,26 @@ exit 1 @@ -508,6 +526,25 @@ cp %{aliyuncli_dir}/LICENSE %{aliyuncli}_LICENSE
%patch203 -p1 %patch1004 -p1
%patch204 -p1 %endif
+# WRS +# STX
+%patch1105 -p1 +%patch1105 -p1
+%patch1106 -p1 +%patch1106 -p1
+%patch1107 -p1 +%patch1107 -p1
@ -58,7 +57,6 @@ index a16660a..ec85fc2 100644
+%patch1117 -p1 +%patch1117 -p1
+%patch1118 -p1 +%patch1118 -p1
+%patch1119 -p1 +%patch1119 -p1
+%patch1120 -p1
+%patch1121 -p1 +%patch1121 -p1
+%patch1122 -p1 +%patch1122 -p1
+ +

View File

@ -30,11 +30,10 @@ diff --git a/heartbeat/LVM b/heartbeat/LVM
index 893ece8..1efb207 100755 index 893ece8..1efb207 100755
--- a/heartbeat/LVM --- a/heartbeat/LVM
+++ b/heartbeat/LVM +++ b/heartbeat/LVM
@@ -338,19 +338,16 @@ LVM_status() { @@ -191,18 +191,15 @@ LVM_status() {
fi fi
fi fi
fi
-
- if [ -d /dev/$1 ]; then - if [ -d /dev/$1 ]; then
- test "`cd /dev/$1 && ls`" != "" - test "`cd /dev/$1 && ls`" != ""
- rc=$? - rc=$?
@ -42,7 +41,7 @@ index 893ece8..1efb207 100755
- ocf_exit_reason "VG $1 with no logical volumes is not supported by this RA!" - ocf_exit_reason "VG $1 with no logical volumes is not supported by this RA!"
- fi - fi
- fi - fi
-
- if [ $rc -ne 0 ]; then - if [ $rc -ne 0 ]; then
+ # Ask lvm whether the volume group is active. This maps to + # Ask lvm whether the volume group is active. This maps to
+ # the question "Are there any logical volumes that are active in + # the question "Are there any logical volumes that are active in
@ -53,9 +52,9 @@ index 893ece8..1efb207 100755
rc=$OCF_NOT_RUNNING rc=$OCF_NOT_RUNNING
else else
+ rc=0 + rc=0
case $(get_vg_mode) in lvm_status
1) # exclusive with tagging. rc=$?
# If vg is running, make sure the correct tag is present. Otherwise we fi
-- --
2.7.4 2.7.4

View File

@ -1,36 +0,0 @@
From 9cdb2de3b5f1d08d74a762cfda2ade16692ef9db Mon Sep 17 00:00:00 2001
From: Al Bailey <Al.Bailey@windriver.com>
Date: Mon, 28 May 2018 14:09:47 -0500
Subject: [PATCH] WRS. Re-enable background execution of arp commands.
Typical ARP commands are taking 6 seconds due to no responses back after 7 attempts.
This change allows that delay to be backgrounded
---
heartbeat/IPaddr2 | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/heartbeat/IPaddr2 b/heartbeat/IPaddr2
index 59620d2..86009b9 100755
--- a/heartbeat/IPaddr2
+++ b/heartbeat/IPaddr2
@@ -719,12 +719,13 @@ run_send_arp() {
if [ $ARP_COUNT -ne 0 ] ; then
ARGS="-i $OCF_RESKEY_arp_interval -c $ARP_COUNT -p $SENDARPPIDFILE -I $NIC -m $MY_MAC $OCF_RESKEY_ip"
ocf_log $LOGLEVEL "$SENDARP $ARGS"
- output=$($SENDARP $ARGS 2>&1)
+ if ocf_is_true $OCF_RESKEY_arp_bg; then
+ ($SENDARP $ARGS || ocf_log err "Could not send gratuitous arps")& >&2
+ else
+ $SENDARP $ARGS || ocf_log err "Could not send gratuitous arps"
+ fi
rc=$?
if [ $rc -ne $OCF_SUCCESS ]; then
- if ! ocf_is_true $OCF_RESKEY_arp_bg; then
- ocf_log err "send_arp output: $output"
- fi
ocf_exit_reason "Could not send gratuitous arps"
exit $OCF_ERR_GENERIC
fi
--
1.8.3.1

View File

@ -15,7 +15,7 @@ index 27f03d2..af821b2 100755
+++ b/heartbeat/Filesystem +++ b/heartbeat/Filesystem
@@ -2,6 +2,8 @@ @@ -2,6 +2,8 @@
# #
# Support: linux-ha@lists.linux-ha.org # Support: users@clusterlabs.org
# License: GNU General Public License (GPL) # License: GNU General Public License (GPL)
+# +#
+# Copyright (c) 2014 Wind River Systems, Inc. All rights reserved. +# Copyright (c) 2014 Wind River Systems, Inc. All rights reserved.
@ -27,7 +27,7 @@ index e435e7b..c11fed7 100755
--- a/heartbeat/LVM --- a/heartbeat/LVM
+++ b/heartbeat/LVM +++ b/heartbeat/LVM
@@ -10,6 +10,7 @@ @@ -10,6 +10,7 @@
# Support: linux-ha@lists.linux-ha.org # Support: users@clusterlabs.org
# License: GNU General Public License (GPL) # License: GNU General Public License (GPL)
# Copyright: (C) 2002 - 2005 International Business Machines, Inc. # Copyright: (C) 2002 - 2005 International Business Machines, Inc.
+# Copyright (c) 2014 Wind River Systems, Inc. All rights reserved. +# Copyright (c) 2014 Wind River Systems, Inc. All rights reserved.
@ -38,7 +38,7 @@ diff --git a/heartbeat/pgsql b/heartbeat/pgsql
index 794f85e..b176b1d 100755 index 794f85e..b176b1d 100755
--- a/heartbeat/pgsql --- a/heartbeat/pgsql
+++ b/heartbeat/pgsql +++ b/heartbeat/pgsql
@@ -9,6 +9,7 @@ @@ -10,6 +10,7 @@
# #
# Copyright: 2006-2012 Serge Dubrouski <sergeyfd@gmail.com> # Copyright: 2006-2012 Serge Dubrouski <sergeyfd@gmail.com>
# and other Linux-HA contributors # and other Linux-HA contributors

View File

@ -28,7 +28,7 @@ index d834096..8cd9c6b 100755
# #
# #
# This assumes you want to manage a filesystem on a shared (SCSI) bus, # This assumes you want to manage a filesystem on a shared (SCSI) bus,
@@ -1137,20 +1139,65 @@ if [ "$OP" != "monitor" ]; then @@ -822,18 +824,63 @@ if [ "$OP" != "monitor" ]; then
ocf_log info "Running $OP for $DEVICE on $MOUNTPOINT" ocf_log info "Running $OP for $DEVICE on $MOUNTPOINT"
fi fi
@ -61,8 +61,6 @@ index d834096..8cd9c6b 100755
+ fi + fi
+} +}
+ +
# These operations do not require the clone checking + OCFS2
# initialization.
case $OP in case $OP in
status) Filesystem_status status) Filesystem_status
- exit $? - exit $?
@ -97,7 +95,7 @@ index d834096..8cd9c6b 100755
;; ;;
esac esac
@@ -1199,6 +1246,12 @@ fi @@ -879,6 +926,12 @@ fi
case $OP in case $OP in
start) Filesystem_start start) Filesystem_start
@ -108,8 +106,8 @@ index d834096..8cd9c6b 100755
+ fi + fi
+ exit $rc + exit $rc
;; ;;
notify) Filesystem_notify *) usage
;; exit $OCF_ERR_UNIMPLEMENTED
diff --git a/heartbeat/LVM b/heartbeat/LVM diff --git a/heartbeat/LVM b/heartbeat/LVM
index 425a60a..ba6c198 100755 index 425a60a..ba6c198 100755
--- a/heartbeat/LVM --- a/heartbeat/LVM
@ -122,7 +120,7 @@ index 425a60a..ba6c198 100755
# #
####################################################################### #######################################################################
# Initialization: # Initialization:
@@ -699,6 +700,34 @@ then @@ -406,6 +407,34 @@ then
exit $OCF_ERR_CONFIGURED exit $OCF_ERR_CONFIGURED
fi fi
@ -157,7 +155,7 @@ index 425a60a..ba6c198 100755
# Get the LVM version number, for this to work we assume(thanks to panjiam): # Get the LVM version number, for this to work we assume(thanks to panjiam):
# #
# LVM1 outputs like this # LVM1 outputs like this
@@ -740,16 +769,37 @@ case "$1" in @@ -449,16 +478,37 @@ case "$1" in
start) start)
LVM_validate_all LVM_validate_all
LVM_start $VOLUME LVM_start $VOLUME

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/IPaddr2 b/heartbeat/IPaddr2
index 86009b9..2da5c5e 100755 index 86009b9..2da5c5e 100755
--- a/heartbeat/IPaddr2 --- a/heartbeat/IPaddr2
+++ b/heartbeat/IPaddr2 +++ b/heartbeat/IPaddr2
@@ -885,12 +885,8 @@ ip_start() { @@ -968,12 +968,8 @@ ip_start() {
then then
exit $OCF_SUCCESS exit $OCF_SUCCESS
else else
@ -26,7 +26,7 @@ index 86009b9..2da5c5e 100755
fi fi
fi fi
@@ -954,12 +950,8 @@ ip_start() { @@ -1037,12 +1033,8 @@ ip_start() {
then then
exit $OCF_SUCCESS exit $OCF_SUCCESS
else else
@ -41,7 +41,7 @@ index 86009b9..2da5c5e 100755
fi fi
} }
@@ -1040,12 +1032,8 @@ ip_monitor() { @@ -1123,12 +1115,8 @@ ip_monitor() {
then then
return $OCF_SUCCESS return $OCF_SUCCESS
else else
@ -52,7 +52,7 @@ index 86009b9..2da5c5e 100755
- return $OCF_NOT_RUNNING - return $OCF_NOT_RUNNING
- fi - fi
+ ocf_log info "NIC $NIC is DOWN" + ocf_log info "NIC $NIC is DOWN"
+ return $OCF_SUCCESS + exit $OCF_SUCCESS
fi fi
;; ;;
partial|no|partial2) partial|no|partial2)

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/IPaddr2 b/heartbeat/IPaddr2
index 2da5c5e..79dbdcf 100755 index 2da5c5e..79dbdcf 100755
--- a/heartbeat/IPaddr2 --- a/heartbeat/IPaddr2
+++ b/heartbeat/IPaddr2 +++ b/heartbeat/IPaddr2
@@ -584,10 +584,18 @@ add_interface () { @@ -622,10 +622,18 @@ add_interface () {
add_ipv6_addrlabel $ipaddr add_ipv6_addrlabel $ipaddr
fi fi

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/IPaddr2 b/heartbeat/IPaddr2
index aef6dc7..67a7ca3 100755 index aef6dc7..67a7ca3 100755
--- a/heartbeat/IPaddr2 --- a/heartbeat/IPaddr2
+++ b/heartbeat/IPaddr2 +++ b/heartbeat/IPaddr2
@@ -880,7 +880,12 @@ ip_start() { @@ -964,7 +964,12 @@ ip_start() {
local ip_status=`ip_served` local ip_status=`ip_served`
if [ "$ip_status" = "ok" ]; then if [ "$ip_status" = "ok" ]; then
@ -24,8 +24,8 @@ index aef6dc7..67a7ca3 100755
+ fi + fi
fi fi
if [ -n "$IP_CIP" ] && [ $ip_status = "no" ] || [ $ip_status = "partial2" ]; then if [ -n "$IP_CIP" ] && ([ $ip_status = "no" ] || [ $ip_status = "partial2" ]); then
@@ -939,7 +944,12 @@ ip_start() { @@ -1023,7 +1028,12 @@ ip_start() {
fi fi
;; ;;
esac esac
@ -39,10 +39,10 @@ index aef6dc7..67a7ca3 100755
} }
ip_stop() { ip_stop() {
@@ -1015,7 +1025,12 @@ ip_monitor() { @@ -1099,7 +1109,12 @@ ip_monitor() {
case $ip_status in case $ip_status in
ok) ok)
$ARP_SEND_FUN refresh run_arp_sender refresh
- return $OCF_SUCCESS - return $OCF_SUCCESS
+ if [ -n "`ip link show $NIC | grep \"state UP\"`" ] + if [ -n "`ip link show $NIC | grep \"state UP\"`" ]
+ then + then

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/IPaddr2 b/heartbeat/IPaddr2
index 67a7ca3..2cd822d 100755 index 67a7ca3..2cd822d 100755
--- a/heartbeat/IPaddr2 --- a/heartbeat/IPaddr2
+++ b/heartbeat/IPaddr2 +++ b/heartbeat/IPaddr2
@@ -884,7 +884,12 @@ ip_start() { @@ -968,7 +968,12 @@ ip_start() {
then then
exit $OCF_SUCCESS exit $OCF_SUCCESS
else else
@ -25,7 +25,7 @@ index 67a7ca3..2cd822d 100755
fi fi
fi fi
@@ -948,7 +953,12 @@ ip_start() { @@ -1032,7 +1037,12 @@ ip_start() {
then then
exit $OCF_SUCCESS exit $OCF_SUCCESS
else else
@ -39,7 +39,7 @@ index 67a7ca3..2cd822d 100755
fi fi
} }
@@ -1029,7 +1039,12 @@ ip_monitor() { @@ -1113,7 +1123,12 @@ ip_monitor() {
then then
return $OCF_SUCCESS return $OCF_SUCCESS
else else

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/IPaddr2 b/heartbeat/IPaddr2
index 2cd822d..59620d2 100755 index 2cd822d..59620d2 100755
--- a/heartbeat/IPaddr2 --- a/heartbeat/IPaddr2
+++ b/heartbeat/IPaddr2 +++ b/heartbeat/IPaddr2
@@ -880,7 +880,7 @@ ip_start() { @@ -964,7 +964,7 @@ ip_start() {
local ip_status=`ip_served` local ip_status=`ip_served`
if [ "$ip_status" = "ok" ]; then if [ "$ip_status" = "ok" ]; then
@ -20,7 +20,7 @@ index 2cd822d..59620d2 100755
then then
exit $OCF_SUCCESS exit $OCF_SUCCESS
else else
@@ -949,7 +949,7 @@ ip_start() { @@ -1033,7 +1033,7 @@ ip_start() {
fi fi
;; ;;
esac esac
@ -29,10 +29,10 @@ index 2cd822d..59620d2 100755
then then
exit $OCF_SUCCESS exit $OCF_SUCCESS
else else
@@ -1035,7 +1035,7 @@ ip_monitor() { @@ -1119,7 +1119,7 @@ ip_monitor() {
case $ip_status in case $ip_status in
ok) ok)
$ARP_SEND_FUN refresh run_arp_sender refresh
- if [ -n "`ip link show $NIC | grep \"state UP\"`" ] - if [ -n "`ip link show $NIC | grep \"state UP\"`" ]
+ if [ -n "`ip link show $NIC | grep \"state UP\"`" ] || [ "$NIC" = "lo" ] + if [ -n "`ip link show $NIC | grep \"state UP\"`" ] || [ "$NIC" = "lo" ]
then then

View File

@ -30,7 +30,7 @@ diff --git a/heartbeat/LVM b/heartbeat/LVM
index 1efb207..bde381c 100755 index 1efb207..bde381c 100755
--- a/heartbeat/LVM --- a/heartbeat/LVM
+++ b/heartbeat/LVM +++ b/heartbeat/LVM
@@ -601,6 +601,81 @@ EOF @@ -365,6 +365,81 @@ LVM_start() {
} }
# #
@ -112,7 +112,7 @@ index 1efb207..bde381c 100755
# Disable the LVM volume # Disable the LVM volume
# #
LVM_stop() { LVM_stop() {
@@ -632,6 +707,7 @@ LVM_stop() { @@ -393,6 +468,7 @@ LVM_stop() {
break break
fi fi

View File

@ -4,14 +4,14 @@ Date: Mon, 2 Oct 2017 15:12:54 -0400
Subject: [PATCH 06/13] WRS: Patch1110: lvm_vg_activation.patch Subject: [PATCH 06/13] WRS: Patch1110: lvm_vg_activation.patch
--- ---
heartbeat/LVM | 130 +++++++++++++++++++++++++++++++++++++++++++++++++++------- heartbeat/LVM | 119 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++--
1 file changed, 116 insertions(+), 14 deletions(-) 1 file changed, 116 insertions(+), 3 deletions(-)
diff --git a/heartbeat/LVM b/heartbeat/LVM diff --git a/heartbeat/LVM b/heartbeat/LVM
index b0ca87a..38092f9 100755 index b0ca87a..38092f9 100755
--- a/heartbeat/LVM --- a/heartbeat/LVM
+++ b/heartbeat/LVM +++ b/heartbeat/LVM
@@ -437,6 +437,81 @@ retry_exclusive_start() @@ -222,6 +222,81 @@ LVM_status() {
} }
# #
@ -93,24 +93,13 @@ index b0ca87a..38092f9 100755
# Enable LVM volume # Enable LVM volume
# #
LVM_start() { LVM_start() {
@@ -477,20 +552,47 @@ EOF @@ -241,9 +316,47 @@ LVM_start() {
: ;; ocf_run vgscan
esac fi
- if ! ocf_run vgchange $vgchange_options $vg; then - lvm_pre_activate || exit
- if [ $clvmd -eq 0 ]; then - ocf_run vgchange $vgchange_activate_options $vg
- return $OCF_ERR_GENERIC - lvm_post_activate $?
- fi
-
- # Failure to exclusively activate cluster vg.:
- # This could be caused by a remotely active LV, Attempt
- # to disable volume group cluster wide and try again.
- # Allow for some settling
- sleep 5
- if ! retry_exclusive_start; then
- return $OCF_ERR_GENERIC
- fi
- fi
+ # Kick off activation of all volumes. If it doesn't complete within + # Kick off activation of all volumes. If it doesn't complete within
+ # the timeout period, then we'll log the not-yet-activated volumes and + # the timeout period, then we'll log the not-yet-activated volumes and
+ # continue on. + # continue on.

View File

@ -5,50 +5,44 @@ Subject: [PATCH 1/1] Notify rmon of shutdown before shutting down LVM and
Filesystem Filesystem
--- ---
heartbeat/Filesystem | 9 +++++---- heartbeat/Filesystem | 5 +++--
heartbeat/LVM | 9 +++++---- heartbeat/LVM | 5 +++--
2 files changed, 10 insertions(+), 8 deletions(-) 2 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/heartbeat/Filesystem b/heartbeat/Filesystem diff --git a/heartbeat/Filesystem b/heartbeat/Filesystem
index 05e4097..d5f3417 100755 index 05e4097..d5f3417 100755
--- a/heartbeat/Filesystem --- a/heartbeat/Filesystem
+++ b/heartbeat/Filesystem +++ b/heartbeat/Filesystem
@@ -1200,10 +1200,11 @@ case $OP in @@ -883,9 +883,10 @@ case $OP in
validate-all) Filesystem_validate_all validate-all) Filesystem_validate_all
exit $? exit $?
;; ;;
- stop) Filesystem_stop - stop) Filesystem_stop
- rc=$? - rc=$?
- rmon_notify "disabled" 300
- exit $rc
+ stop) + stop)
+ rmon_notify "disabled" 300 rmon_notify "disabled" 300
+ Filesystem_stop + Filesystem_stop
+ rc=$? + rc=$?
+ exit $rc exit $rc
;; ;;
esac esac
diff --git a/heartbeat/LVM b/heartbeat/LVM diff --git a/heartbeat/LVM b/heartbeat/LVM
index 38092f9..893ece8 100755 index 38092f9..893ece8 100755
--- a/heartbeat/LVM --- a/heartbeat/LVM
+++ b/heartbeat/LVM +++ b/heartbeat/LVM
@@ -879,10 +879,11 @@ case "$1" in @@ -599,9 +599,10 @@ case "$1" in
fi fi
exit $rc;; exit $rc;;
- stop) LVM_stop $VOLUME - stop) LVM_stop $VOLUME
- rc=$? - rc=$?
- rmon_notify "disabled" 300
- exit $rc;;
+ stop) + stop)
+ rmon_notify "disabled" 300 rmon_notify "disabled" 300
+ LVM_stop $VOLUME + LVM_stop $VOLUME
+ rc=$? + rc=$?
+ exit $rc;; exit $rc;;
status) LVM_status $VOLUME $1 status) LVM_status $VOLUME $1
rc=$?
-- --
2.7.4 2.7.4

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/ocf-shellfuncs.in b/heartbeat/ocf-shellfuncs.in
index 3565e20..688c150 100644 index 3565e20..688c150 100644
--- a/heartbeat/ocf-shellfuncs.in --- a/heartbeat/ocf-shellfuncs.in
+++ b/heartbeat/ocf-shellfuncs.in +++ b/heartbeat/ocf-shellfuncs.in
@@ -180,9 +180,9 @@ hadate() { @@ -176,9 +176,9 @@ hadate() {
set_logtag() { set_logtag() {
if [ -z "$HA_LOGTAG" ]; then if [ -z "$HA_LOGTAG" ]; then
if [ -n "$OCF_RESOURCE_INSTANCE" ]; then if [ -n "$OCF_RESOURCE_INSTANCE" ]; then

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/pgsql b/heartbeat/pgsql
index 768608e..28cc046 100755 index 768608e..28cc046 100755
--- a/heartbeat/pgsql --- a/heartbeat/pgsql
+++ b/heartbeat/pgsql +++ b/heartbeat/pgsql
@@ -38,6 +38,7 @@ get_pgsql_param() { @@ -46,6 +46,7 @@ get_pgsql_param() {
OCF_RESKEY_pgctl_default=/usr/bin/pg_ctl OCF_RESKEY_pgctl_default=/usr/bin/pg_ctl
OCF_RESKEY_psql_default=/usr/bin/psql OCF_RESKEY_psql_default=/usr/bin/psql
OCF_RESKEY_pgdata_default=/var/lib/pgsql/data OCF_RESKEY_pgdata_default=/var/lib/pgsql/data
@ -19,7 +19,7 @@ index 768608e..28cc046 100755
OCF_RESKEY_pgdba_default=postgres OCF_RESKEY_pgdba_default=postgres
OCF_RESKEY_pghost_default="" OCF_RESKEY_pghost_default=""
OCF_RESKEY_pgport_default=5432 OCF_RESKEY_pgport_default=5432
@@ -67,10 +68,11 @@ OCF_RESKEY_stop_escalate_in_slave_default=30 @@ -78,11 +79,12 @@ OCF_RESKEY_replication_slot_name_default=""
: ${OCF_RESKEY_pgctl=${OCF_RESKEY_pgctl_default}} : ${OCF_RESKEY_pgctl=${OCF_RESKEY_pgctl_default}}
: ${OCF_RESKEY_psql=${OCF_RESKEY_psql_default}} : ${OCF_RESKEY_psql=${OCF_RESKEY_psql_default}}
: ${OCF_RESKEY_pgdata=${OCF_RESKEY_pgdata_default}} : ${OCF_RESKEY_pgdata=${OCF_RESKEY_pgdata_default}}
@ -27,12 +27,13 @@ index 768608e..28cc046 100755
: ${OCF_RESKEY_pgdba=${OCF_RESKEY_pgdba_default}} : ${OCF_RESKEY_pgdba=${OCF_RESKEY_pgdba_default}}
: ${OCF_RESKEY_pghost=${OCF_RESKEY_pghost_default}} : ${OCF_RESKEY_pghost=${OCF_RESKEY_pghost_default}}
: ${OCF_RESKEY_pgport=${OCF_RESKEY_pgport_default}} : ${OCF_RESKEY_pgport=${OCF_RESKEY_pgport_default}}
: ${OCF_RESKEY_pglibs=${OCF_RESKEY_pglibs_default}}
-: ${OCF_RESKEY_config=${OCF_RESKEY_pgdata}/postgresql.conf} -: ${OCF_RESKEY_config=${OCF_RESKEY_pgdata}/postgresql.conf}
+: ${OCF_RESKEY_config=${OCF_RESKEY_pgconf}/postgresql.conf} +: ${OCF_RESKEY_config=${OCF_RESKEY_pgconf}/postgresql.conf}
: ${OCF_RESKEY_start_opt=${OCF_RESKEY_start_opt_default}} : ${OCF_RESKEY_start_opt=${OCF_RESKEY_start_opt_default}}
: ${OCF_RESKEY_ctl_opt=${OCF_RESKEY_ctl_opt_default}}
: ${OCF_RESKEY_pgdb=${OCF_RESKEY_pgdb_default}} : ${OCF_RESKEY_pgdb=${OCF_RESKEY_pgdb_default}}
: ${OCF_RESKEY_logfile=${OCF_RESKEY_logfile_default}} @@ -180,6 +182,14 @@ Path to PostgreSQL data directory.
@@ -166,6 +168,14 @@ Path to PostgreSQL data directory.
<content type="string" default="${OCF_RESKEY_pgdata_default}" /> <content type="string" default="${OCF_RESKEY_pgdata_default}" />
</parameter> </parameter>
@ -47,7 +48,7 @@ index 768608e..28cc046 100755
<parameter name="pgdba" unique="0" required="0"> <parameter name="pgdba" unique="0" required="0">
<longdesc lang="en"> <longdesc lang="en">
User that owns PostgreSQL. User that owns PostgreSQL.
@@ -220,7 +230,7 @@ SQL script that will be used for monitor operations. @@ -243,7 +253,7 @@ SQL script that will be used for monitor operations.
Path to the PostgreSQL configuration file for the instance. Path to the PostgreSQL configuration file for the instance.
</longdesc> </longdesc>
<shortdesc lang="en">Configuration file</shortdesc> <shortdesc lang="en">Configuration file</shortdesc>
@ -56,9 +57,9 @@ index 768608e..28cc046 100755
</parameter> </parameter>
<parameter name="pgdb" unique="0" required="0"> <parameter name="pgdb" unique="0" required="0">
@@ -549,6 +559,12 @@ pgsql_real_start() { @@ -630,6 +640,12 @@ pgsql_real_start() {
ocf_log debug "PostgreSQL still hasn't started yet. Waiting..." fi
done fi
+ # WRS: Create an unversioned symlink under /var/run so SM can easily + # WRS: Create an unversioned symlink under /var/run so SM can easily
+ # find the PID file. + # find the PID file.
@ -69,8 +70,8 @@ index 768608e..28cc046 100755
ocf_log info "PostgreSQL is started." ocf_log info "PostgreSQL is started."
return $rc return $rc
} }
@@ -1756,10 +1772,11 @@ fi @@ -2078,10 +2094,11 @@ then
fi
PIDFILE=${OCF_RESKEY_pgdata}/postmaster.pid PIDFILE=${OCF_RESKEY_pgdata}/postmaster.pid
+PIDFILE_SYMLINK=/var/run/postmaster.pid +PIDFILE_SYMLINK=/var/run/postmaster.pid
@ -81,7 +82,7 @@ index 768608e..28cc046 100755
+RECOVERY_CONF=${OCF_RESKEY_pgconf}/recovery.conf +RECOVERY_CONF=${OCF_RESKEY_pgconf}/recovery.conf
NODENAME=$(ocf_local_nodename | tr '[A-Z]' '[a-z]') NODENAME=$(ocf_local_nodename | tr '[A-Z]' '[a-z]')
if is_replication; then case "$1" in
-- --
1.9.1 1.9.1

View File

@ -11,7 +11,7 @@ diff --git a/heartbeat/Filesystem b/heartbeat/Filesystem
index f536298..05e4097 100755 index f536298..05e4097 100755
--- a/heartbeat/Filesystem --- a/heartbeat/Filesystem
+++ b/heartbeat/Filesystem +++ b/heartbeat/Filesystem
@@ -804,6 +804,10 @@ signal_processes() { @@ -503,6 +503,10 @@ signal_processes() {
} }
try_umount() { try_umount() {
local SUB=$1 local SUB=$1

View File

@ -1,2 +1,2 @@
mirror:Source/resource-agents-3.9.5-124.el7.src.rpm mirror:Source/resource-agents-4.1.1-12.el7_6.7.src.rpm