058b24e58a
- Update mdadm to latest upstream state upto commit 582945c2d3bb. (jsc#PED-7542) 1) The testing changes are not included here. 2) Code clean up, and more helper routines added for Manage.c, Monitor.c, mdadm.c, ReadMe.c, super-intel.c, super0.c, super1.c, Create.c, Incremental.c and so on. 3) Man page update for mdadm.8.in. 4) Several memory leak and double free fixes. 5) Check /etc/initrd-release for whether systemd running on an initrd. - Manage: Block unsafe member failing 0062-Manage-Block-unsafe-member-failing.patch - Mdmonitor: Split alert() into separate functions 0063-Mdmonitor-Split-alert-into-separate-functions.patch - Monitor: block if monitor modes are combined. 0064-Monitor-block-if-monitor-modes-are-combined.patch - Update mdadm Monitor manual. 0065-Update-mdadm-Monitor-manual.patch - mdadm: create ident_init() 0066-mdadm-create-ident_init.patch - mdadm: Add option validation for --update-subarray 0067-mdadm-Add-option-validation-for-update-subarray.patch - Fix --update-subarray on active volume 0068-Fix-update-subarray-on-active-volume.patch - Add code specific update options to enum. 0069-Add-code-specific-update-options-to-enum.patch - super-ddf: Remove update_super_ddf. 0070-super-ddf-Remove-update_super_ddf.patch - super0: refactor the code for enum 0071-super0-refactor-the-code-for-enum.patch - super1: refactor the code for enum OBS-URL: https://build.opensuse.org/request/show/1137473 OBS-URL: https://build.opensuse.org/package/show/Base:System/mdadm?expand=0&rev=231
42 lines
1.3 KiB
Diff
42 lines
1.3 KiB
Diff
From f40ac0e7e6043361ad12e9db97c07e56c3977cf6 Mon Sep 17 00:00:00 2001
|
|
From: Blazej Kucman <blazej.kucman@intel.com>
|
|
Date: Mon, 19 Dec 2022 11:21:57 +0100
|
|
Subject: [PATCH] Monitor: block if monitor modes are combined.
|
|
|
|
Block monitoring start if --scan mode and MD devices list are combined.
|
|
|
|
Signed-off-by: Blazej Kucman <blazej.kucman@intel.com>
|
|
Signed-off-by: Jes Sorensen <jes@trained-monkey.org>
|
|
---
|
|
Monitor.c | 7 ++++++-
|
|
1 file changed, 6 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/Monitor.c b/Monitor.c
|
|
index 0036e8c..188cb8b 100644
|
|
--- a/Monitor.c
|
|
+++ b/Monitor.c
|
|
@@ -123,7 +123,7 @@ int Monitor(struct mddev_dev *devlist,
|
|
* and if we can get_disk_info and find a name
|
|
* Then we hot-remove and hot-add to the other array
|
|
*
|
|
- * If devlist is NULL, then we can monitor everything because --scan
|
|
+ * If devlist is NULL, then we can monitor everything if --scan
|
|
* was given. We get an initial list from config file and add anything
|
|
* that appears in /proc/mdstat
|
|
*/
|
|
@@ -136,6 +136,11 @@ int Monitor(struct mddev_dev *devlist,
|
|
struct mddev_ident *mdlist;
|
|
int delay_for_event = c->delay;
|
|
|
|
+ if (devlist && c->scan) {
|
|
+ pr_err("Devices list and --scan option cannot be combined - not monitoring.\n");
|
|
+ return 1;
|
|
+ }
|
|
+
|
|
if (!mailaddr)
|
|
mailaddr = conf_get_mailaddr();
|
|
|
|
--
|
|
2.35.3
|
|
|