Auto sync2gitlab import of resource-agents-4.9.0-38.el8.src.rpm
This commit is contained in:
parent
5223c25e87
commit
81cb8a24e2
109
bz2157873-4-exportfs-pgsql-validate-all-fixes.patch
Normal file
109
bz2157873-4-exportfs-pgsql-validate-all-fixes.patch
Normal file
@ -0,0 +1,109 @@
|
|||||||
|
From 8b78251b24446c0a603a533ecc0b632dd14c752b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
|
||||||
|
Date: Wed, 11 Jan 2023 13:22:24 +0100
|
||||||
|
Subject: [PATCH 1/2] exportfs: move testdir() to start-action to avoid failing
|
||||||
|
during resource creation (validate-all) and make it create the directory if
|
||||||
|
it doesnt exist
|
||||||
|
|
||||||
|
---
|
||||||
|
heartbeat/exportfs | 25 ++++++++++++++-----------
|
||||||
|
1 file changed, 14 insertions(+), 11 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/heartbeat/exportfs b/heartbeat/exportfs
|
||||||
|
index c10777fa9..e0b66b9ee 100755
|
||||||
|
--- a/heartbeat/exportfs
|
||||||
|
+++ b/heartbeat/exportfs
|
||||||
|
@@ -301,6 +301,16 @@ exportfs_monitor ()
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
+testdir() {
|
||||||
|
+ if [ ! -d $1 ]; then
|
||||||
|
+ mkdir -p "$1"
|
||||||
|
+ if [ $? -ne 0 ]; then
|
||||||
|
+ ocf_exit_reason "Unable to create directory $1"
|
||||||
|
+ return 1
|
||||||
|
+ fi
|
||||||
|
+ fi
|
||||||
|
+ return 0
|
||||||
|
+}
|
||||||
|
export_one() {
|
||||||
|
local dir=$1
|
||||||
|
local opts sep
|
||||||
|
@@ -331,6 +341,10 @@ export_one() {
|
||||||
|
}
|
||||||
|
exportfs_start ()
|
||||||
|
{
|
||||||
|
+ if ! forall testdir; then
|
||||||
|
+ return $OCF_ERR_INSTALLED
|
||||||
|
+ fi
|
||||||
|
+
|
||||||
|
if exportfs_monitor; then
|
||||||
|
ocf_log debug "already exported"
|
||||||
|
return $OCF_SUCCESS
|
||||||
|
@@ -428,14 +442,6 @@ exportfs_stop ()
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
-testdir() {
|
||||||
|
- if [ ! -d $1 ]; then
|
||||||
|
- ocf_is_probe ||
|
||||||
|
- ocf_log err "$1 does not exist or is not a directory"
|
||||||
|
- return 1
|
||||||
|
- fi
|
||||||
|
- return 0
|
||||||
|
-}
|
||||||
|
exportfs_validate_all ()
|
||||||
|
{
|
||||||
|
if echo "$OCF_RESKEY_fsid" | grep -q -F ','; then
|
||||||
|
@@ -447,9 +453,6 @@ exportfs_validate_all ()
|
||||||
|
ocf_exit_reason "use integer fsid when exporting multiple directories"
|
||||||
|
return $OCF_ERR_CONFIGURED
|
||||||
|
fi
|
||||||
|
- if ! forall testdir; then
|
||||||
|
- return $OCF_ERR_INSTALLED
|
||||||
|
- fi
|
||||||
|
}
|
||||||
|
|
||||||
|
for dir in $OCF_RESKEY_directory; do
|
||||||
|
|
||||||
|
From 8acbd8ea5a87a8adc33f47a06f8b0fb4a006cbe8 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
|
||||||
|
Date: Wed, 11 Jan 2023 13:25:57 +0100
|
||||||
|
Subject: [PATCH 2/2] pgsql: dont run promotable checks during validate-all
|
||||||
|
action
|
||||||
|
|
||||||
|
---
|
||||||
|
heartbeat/pgsql | 5 +++--
|
||||||
|
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/heartbeat/pgsql b/heartbeat/pgsql
|
||||||
|
index aa8a13a84..a99946af5 100755
|
||||||
|
--- a/heartbeat/pgsql
|
||||||
|
+++ b/heartbeat/pgsql
|
||||||
|
@@ -1937,7 +1937,7 @@ pgsql_validate_all() {
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
- if is_replication; then
|
||||||
|
+ if [ "$OCF_CHECK_LEVEL" -eq 10 ] && is_replication; then
|
||||||
|
REP_MODE_CONF=${OCF_RESKEY_tmpdir}/rep_mode.conf
|
||||||
|
PGSQL_LOCK=${OCF_RESKEY_tmpdir}/PGSQL.lock
|
||||||
|
XLOG_NOTE_FILE=${OCF_RESKEY_tmpdir}/xlog_note
|
||||||
|
@@ -2002,7 +2002,7 @@ pgsql_validate_all() {
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
- if [ "$OCF_RESKEY_rep_mode" = "slave" ]; then
|
||||||
|
+ if [ "$OCF_CHECK_LEVEL" -eq 10 ] && [ "$OCF_RESKEY_rep_mode" = "slave" ]; then
|
||||||
|
if ocf_is_ms; then
|
||||||
|
ocf_exit_reason "Replication(rep_mode=slave) does not support Master/Slave configuration."
|
||||||
|
return $OCF_ERR_CONFIGURED
|
||||||
|
@@ -2163,6 +2163,7 @@ case "$1" in
|
||||||
|
exit $OCF_SUCCESS;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
+[ "$__OCF_ACTION" != "validate-all" ] && OCF_CHECK_LEVEL=10
|
||||||
|
pgsql_validate_all
|
||||||
|
rc=$?
|
||||||
|
|
23
bz2157873-5-pgsqlms-alidate-all-OCF_CHECK_LEVEL-10.patch
Normal file
23
bz2157873-5-pgsqlms-alidate-all-OCF_CHECK_LEVEL-10.patch
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
--- ClusterLabs-resource-agents-fd0720f7/heartbeat/pgsqlms 2023-01-16 10:54:30.897188238 +0100
|
||||||
|
+++ pgsqlms 2023-01-10 14:21:19.281286242 +0100
|
||||||
|
@@ -1351,12 +1351,14 @@
|
||||||
|
return $OCF_ERR_ARGS;
|
||||||
|
}
|
||||||
|
|
||||||
|
- $guc = qx{ $POSTGRES -C primary_conninfo -D "$pgdata" $start_opts};
|
||||||
|
- unless ($guc =~ /\bapplication_name='?$nodename'?\b/) {
|
||||||
|
- ocf_exit_reason(
|
||||||
|
- q{Parameter "primary_conninfo" MUST contain 'application_name=%s'. }.
|
||||||
|
- q{It is currently set to '%s'}, $nodename, $guc );
|
||||||
|
- return $OCF_ERR_ARGS;
|
||||||
|
+ if ( $ocf_check_level == 10 ) {
|
||||||
|
+ $guc = qx{ $POSTGRES -C primary_conninfo -D "$pgdata" $start_opts};
|
||||||
|
+ unless ($guc =~ /\bapplication_name='?$nodename'?\b/) {
|
||||||
|
+ ocf_exit_reason(
|
||||||
|
+ q{Parameter "primary_conninfo" MUST contain 'application_name=%s'. }.
|
||||||
|
+ q{It is currently set to '%s'}, $nodename, $guc );
|
||||||
|
+ return $OCF_ERR_ARGS;
|
||||||
|
+ }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
@ -69,7 +69,7 @@
|
|||||||
Name: resource-agents
|
Name: resource-agents
|
||||||
Summary: Open Source HA Reusable Cluster Resource Scripts
|
Summary: Open Source HA Reusable Cluster Resource Scripts
|
||||||
Version: 4.9.0
|
Version: 4.9.0
|
||||||
Release: 37%{?rcver:%{rcver}}%{?numcomm:.%{numcomm}}%{?alphatag:.%{alphatag}}%{?dirty:.%{dirty}}%{?dist}
|
Release: 38%{?rcver:%{rcver}}%{?numcomm:.%{numcomm}}%{?alphatag:.%{alphatag}}%{?dirty:.%{dirty}}%{?dist}
|
||||||
License: GPLv2+ and LGPLv2+
|
License: GPLv2+ and LGPLv2+
|
||||||
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}
|
||||||
@ -134,6 +134,8 @@ Patch42: bz2139131-mysql-common-return-error-if-kill-fails.patch
|
|||||||
Patch43: bz2157873-1-all-ras-validate-all-OCF_CHECK_LEVEL-10.patch
|
Patch43: bz2157873-1-all-ras-validate-all-OCF_CHECK_LEVEL-10.patch
|
||||||
Patch44: bz2157873-2-Filesystem-CTDB-validate-all-improvements.patch
|
Patch44: bz2157873-2-Filesystem-CTDB-validate-all-improvements.patch
|
||||||
Patch45: bz2157873-3-pgsqlms-validate-all-OCF_CHECK_LEVEL-10.patch
|
Patch45: bz2157873-3-pgsqlms-validate-all-OCF_CHECK_LEVEL-10.patch
|
||||||
|
Patch46: bz2157873-4-exportfs-pgsql-validate-all-fixes.patch
|
||||||
|
Patch47: bz2157873-5-pgsqlms-alidate-all-OCF_CHECK_LEVEL-10.patch
|
||||||
|
|
||||||
# bundle patches
|
# bundle patches
|
||||||
Patch1000: 7-gcp-bundled.patch
|
Patch1000: 7-gcp-bundled.patch
|
||||||
@ -359,6 +361,8 @@ exit 1
|
|||||||
%patch43 -p1
|
%patch43 -p1
|
||||||
%patch44 -p1
|
%patch44 -p1
|
||||||
%patch45 -p1
|
%patch45 -p1
|
||||||
|
%patch46 -p1
|
||||||
|
%patch47 -p1
|
||||||
|
|
||||||
chmod 755 heartbeat/nova-compute-wait
|
chmod 755 heartbeat/nova-compute-wait
|
||||||
chmod 755 heartbeat/NovaEvacuate
|
chmod 755 heartbeat/NovaEvacuate
|
||||||
@ -934,7 +938,7 @@ ccs_update_schema > /dev/null 2>&1 ||:
|
|||||||
%{_usr}/lib/ocf/lib/heartbeat/OCF_*.pm
|
%{_usr}/lib/ocf/lib/heartbeat/OCF_*.pm
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Thu Jan 5 2023 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.9.0-37
|
* Mon Jan 16 2023 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.9.0-38
|
||||||
- all agents: dont check notify/promotable settings during
|
- all agents: dont check notify/promotable settings during
|
||||||
validate-action
|
validate-action
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user