- Filesystem: always return OCF_ERR_GENERIC when another device is

mounted on mountpoint to ensure relocation after trying to restart
  (default behaviour)

  Resolves: RHEL-159646
This commit is contained in:
Oyvind Albrigtsen 2026-05-13 09:59:29 +02:00
parent bb24c1b1a8
commit b7e8916d9f
3 changed files with 36 additions and 4 deletions

View File

@ -0,0 +1,28 @@
From f2cfc150da843a6c57bb6f6eebb4e44eb9d23213 Mon Sep 17 00:00:00 2001
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
Date: Wed, 13 May 2026 09:28:59 +0200
Subject: [PATCH] Filesystem: always return OCF_ERR_GENERIC when another device
is mounted on mountpoint to ensure relocation after trying to restart
(default behaviour)
---
heartbeat/Filesystem | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/heartbeat/Filesystem b/heartbeat/Filesystem
index b4f16f17f..f7d2aa34b 100755
--- a/heartbeat/Filesystem
+++ b/heartbeat/Filesystem
@@ -1029,11 +1029,7 @@ Filesystem_status()
rc=$OCF_NOT_RUNNING
else
ocf_exit_reason "Another device ($mounted_device) is already mounted on $MOUNTPOINT"
- if [ "$__OCF_ACTION" = "monitor" ]; then
- rc=$OCF_ERR_GENERIC
- else
- rc=$OCF_ERR_CONFIGURED
- fi
+ rc=$OCF_ERR_GENERIC
fi
fi
else

View File

@ -45,7 +45,7 @@
Name: resource-agents
Summary: Open Source HA Reusable Cluster Resource Scripts
Version: 4.16.0
Release: 58%{?rcver:%{rcver}}%{?numcomm:.%{numcomm}}%{?alphatag:.%{alphatag}}%{?dirty:.%{dirty}}%{?dist}
Release: 59%{?rcver:%{rcver}}%{?numcomm:.%{numcomm}}%{?alphatag:.%{alphatag}}%{?dirty:.%{dirty}}%{?dist}
License: GPL-2.0-or-later AND LGPL-2.1-or-later
URL: https://github.com/ClusterLabs/resource-agents
Source0: %{upstream_prefix}-%{upstream_version}.tar.gz
@ -125,7 +125,8 @@ Patch72: RHEL-156855-podman-etcd-handle-existing-peer-URLs-gracefully-during-for
Patch73: RHEL-150958-db2-set-reintegration-when-promotion-is-successful.patch
Patch74: RHEL-158905-podman-etcd-hardened-monitor-stop-actions.patch
Patch75: RHEL-134709-db2-do-not-use-db2stop-to-avoid-divergence-in-the-log.patch
Patch76: RHEL-159646-Filesystem-do-not-return-CONFIGURED-during-monitor-action.patch
Patch76: RHEL-159646-1-Filesystem-do-not-return-CONFIGURED-during-monitor-action.patch
Patch77: RHEL-159646-2-Filesystem-always-return-OCF_ERR_GENERIC-when-another-device-is-mounted-on-mountpoint.patch
# bundled ha-cloud-support libs
Patch500: ha-cloud-support-aliyun.patch
@ -373,6 +374,7 @@ exit 1
%patch -p1 -P 74
%patch -p1 -P 75
%patch -p1 -P 76
%patch -p1 -P 77
# bundled ha-cloud-support libs
%patch -p1 -P 500
@ -705,8 +707,10 @@ rm -rf %{buildroot}/usr/share/doc/resource-agents
%{_usr}/lib/ocf/lib/heartbeat/OCF_*.pm
%changelog
* Mon May 4 2026 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.16.0-58
- Filesystem: do not return CONFIGURED during monitor-action
* Wed May 13 2026 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.16.0-59
- Filesystem: always return OCF_ERR_GENERIC when another device is
mounted on mountpoint to ensure relocation after trying to restart
(default behaviour)
Resolves: RHEL-159646