!46 回合上游patch: storage-mon: Add logging to daemon mode.
From: @bixiaoyan1 Reviewed-by: @xiangbudaomz Signed-off-by: @xiangbudaomz
This commit is contained in:
commit
4b1d99b042
34
backport-Mid-storage-mon-Add-logging-to-daemon-mode.patch
Normal file
34
backport-Mid-storage-mon-Add-logging-to-daemon-mode.patch
Normal file
@ -0,0 +1,34 @@
|
||||
From 9032181967ea9c5c985e346c51bca6b9997d7287 Mon Sep 17 00:00:00 2001
|
||||
From: Hideo Yamauchi <renayama19661014@ybb.ne.jp>
|
||||
Date: Mon, 27 May 2024 18:12:01 +0900
|
||||
Subject: [PATCH] Mid: storage-mon: Add logging to daemon mode.
|
||||
|
||||
---
|
||||
tools/storage_mon.c | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/tools/storage_mon.c b/tools/storage_mon.c
|
||||
index a9227ef9..f94268f6 100644
|
||||
--- a/tools/storage_mon.c
|
||||
+++ b/tools/storage_mon.c
|
||||
@@ -308,6 +308,8 @@ static int32_t sigchld_handler(int32_t sig, void *data)
|
||||
/* so add the final_score from the exit code of the terminated child process. */
|
||||
if (qb_loop_timer_is_running(storage_mon_poll_handle, expire_handle)) {
|
||||
if (WEXITSTATUS(status) !=0) {
|
||||
+ syslog(LOG_ERR, "Error reading from device %s", devices[index]);
|
||||
+
|
||||
final_score += scores[index];
|
||||
|
||||
/* Update response values immediately in preparation for inquiries from clients. */
|
||||
@@ -403,6 +405,8 @@ static void child_timeout_handler(void *data)
|
||||
if (is_child_runnning()) {
|
||||
for (i=0; i<device_count; i++) {
|
||||
if (test_forks[i] > 0) {
|
||||
+ syslog(LOG_ERR, "Reading from device %s did not complete in %d seconds timeout", devices[i], timeout);
|
||||
+
|
||||
/* If timeout occurs before SIGCHLD, add child process failure score to final_score. */
|
||||
final_score += scores[i];
|
||||
|
||||
--
|
||||
2.25.1
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
Name: resource-agents
|
||||
Summary: Open Source HA Reusable Cluster Resource Scripts
|
||||
Version: 4.13.0
|
||||
Release: 24
|
||||
Release: 25
|
||||
License: GPLv2+ and LGPLv2+
|
||||
URL: https://github.com/ClusterLabs/resource-agents
|
||||
Source0: https://github.com/ClusterLabs/resource-agents/archive/v%{version}.tar.gz
|
||||
@ -29,6 +29,7 @@ Patch0020: Filesystem-fail-when-incorrect-device-mounted-on-mou.patch
|
||||
Patch0021: ocf-shellfuncs-add-curl_retry.patch
|
||||
Patch0022: aws-vpc-move-ip-aws-vpc-route53-awseip-awsvip-add-au.patch
|
||||
Patch0023: AWS-agents-use-curl_retry.patch
|
||||
Patch0024: backport-Mid-storage-mon-Add-logging-to-daemon-mode.patch
|
||||
|
||||
Obsoletes: heartbeat-resources <= %{version}
|
||||
Provides: heartbeat-resources = %{version}
|
||||
@ -127,6 +128,9 @@ export CFLAGS="$(echo '%{optflags}')"
|
||||
%{_mandir}/man8/{ocf-tester.8*,ldirectord.8*}
|
||||
|
||||
%changelog
|
||||
* Fri May 31 2024 bixiaoyan <bixiaoyan@kylinos.cn> - 4.13.0-25
|
||||
- Mid: storage-mon: Add logging to daemon mode.
|
||||
|
||||
* Tue May 07 2024 bizhiyuan <bizhiyuan@kylinos.cn> - 4.13.0-24
|
||||
- AWS agents: use curl_retry()
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user