From: Martin Wilck <mwilck@suse.com>
To: Benjamin Marzinski <bmarzins@redhat.com>,
device-mapper development <dm-devel@redhat.com>
Subject: Re: [PATCH v2 5/7] Fix set_no_path_retry() regression
Date: Mon, 12 Feb 2018 21:13:07 +0100 [thread overview]
Message-ID: <1518466387.2761.62.camel@suse.com> (raw)
In-Reply-To: <1518134167-15938-6-git-send-email-bmarzins@redhat.com>
On Thu, 2018-02-08 at 17:56 -0600, Benjamin Marzinski wrote:
> commit 0f850db7fceb6b2bf4968f3831efd250c17c6138 "multipathd: clean up
> set_no_path_retry" has a bug in it. It made set_no_path_retry
> never reset mpp->retry_ticks, even if the device was in recovery
> mode,
> and there were valid paths. This meant that adding new paths didn't
> remove a device from recovery mode, and queueing could get disabled,
> even while there were valid paths. This patch fixes that.
>
> This patch also fixes a bug in cli_restore_queueing() and
> cli_restore_all_queueing(), where a device that had no_path_retry
> set to "queue" would enter recovery mode (although queueing would
> never actually get disabled).
>
> Cc: Martin Wilck <mwilck@suse.com>
> Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
Reviewed-by: Martin Wilck <mwilck@suse.com>
> ---
> libmultipath/structs_vec.c | 5 +++--
> multipathd/cli_handlers.c | 20 ++++++++++++--------
> 2 files changed, 15 insertions(+), 10 deletions(-)
>
> diff --git a/libmultipath/structs_vec.c b/libmultipath/structs_vec.c
> index fbab61f..0de2221 100644
> --- a/libmultipath/structs_vec.c
> +++ b/libmultipath/structs_vec.c
> @@ -343,9 +343,10 @@ static void set_no_path_retry(struct multipath
> *mpp)
> dm_queue_if_no_path(mpp->alias, 1);
> break;
> default:
> - if (mpp->nr_active > 0)
> + if (mpp->nr_active > 0) {
> + mpp->retry_tick = 0;
> dm_queue_if_no_path(mpp->alias, 1);
> - else if (is_queueing && mpp->retry_tick == 0)
> + } else if (is_queueing && mpp->retry_tick == 0)
> enter_recovery_mode(mpp);
> break;
> }
> diff --git a/multipathd/cli_handlers.c b/multipathd/cli_handlers.c
> index 7f13bc9..80519b1 100644
> --- a/multipathd/cli_handlers.c
> +++ b/multipathd/cli_handlers.c
> @@ -995,10 +995,12 @@ cli_restore_queueing(void *v, char **reply, int
> *len, void *data)
> if (mpp->no_path_retry != NO_PATH_RETRY_UNDEF &&
> mpp->no_path_retry != NO_PATH_RETRY_FAIL) {
> dm_queue_if_no_path(mpp->alias, 1);
> - if (mpp->nr_active > 0)
> - mpp->retry_tick = 0;
> - else
> - enter_recovery_mode(mpp);
> + if (mpp->no_path_retry > 0) {
> + if (mpp->nr_active > 0)
> + mpp->retry_tick = 0;
> + else
> + enter_recovery_mode(mpp);
> + }
> }
> return 0;
> }
> @@ -1019,10 +1021,12 @@ cli_restore_all_queueing(void *v, char
> **reply, int *len, void *data)
> if (mpp->no_path_retry != NO_PATH_RETRY_UNDEF &&
> mpp->no_path_retry != NO_PATH_RETRY_FAIL) {
> dm_queue_if_no_path(mpp->alias, 1);
> - if (mpp->nr_active > 0)
> - mpp->retry_tick = 0;
> - else
> - enter_recovery_mode(mpp);
> + if (mpp->no_path_retry > 0) {
> + if (mpp->nr_active > 0)
> + mpp->retry_tick = 0;
> + else
> + enter_recovery_mode(mpp);
> + }
> }
> }
> return 0;
--
Dr. Martin Wilck <mwilck@suse.com>, Tel. +49 (0)911 74053 2107
SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
next prev parent reply other threads:[~2018-02-12 20:13 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-08 23:56 [PATCH v2 0/7] multipath: miscellaneous bug fixes Benjamin Marzinski
2018-02-08 23:56 ` [PATCH v2 1/7] libmultipath: fix tur checker locking Benjamin Marzinski
2018-02-09 16:15 ` Bart Van Assche
2018-02-09 17:26 ` Benjamin Marzinski
2018-02-09 17:42 ` Bart Van Assche
2018-02-09 20:30 ` Martin Wilck
2018-02-09 23:04 ` Benjamin Marzinski
2018-02-09 23:28 ` Martin Wilck
2018-02-09 23:36 ` Martin Wilck
2018-02-10 0:17 ` Benjamin Marzinski
2018-02-10 16:03 ` Martin Wilck
2018-02-10 0:36 ` Benjamin Marzinski
2018-02-10 16:11 ` Martin Wilck
2018-02-10 19:42 ` Martin Wilck
2018-02-12 18:44 ` Benjamin Marzinski
2018-02-12 19:16 ` Martin Wilck
2018-02-08 23:56 ` [PATCH v2 2/7] multipath: fix DEF_TIMEOUT use Benjamin Marzinski
2018-02-08 23:56 ` [PATCH v2 3/7] multipathd: remove coalesce_paths from ev_add_map Benjamin Marzinski
2018-02-12 20:30 ` Martin Wilck
2018-02-08 23:56 ` [PATCH v2 4/7] multipathd: remove unused configure parameter Benjamin Marzinski
2018-02-08 23:56 ` [PATCH v2 5/7] Fix set_no_path_retry() regression Benjamin Marzinski
2018-02-12 20:13 ` Martin Wilck [this message]
2018-02-08 23:56 ` [PATCH v2 6/7] multipathd: change spurious uevent msg priority Benjamin Marzinski
2018-02-08 23:56 ` [PATCH v2 7/7] multipath: print sysfs state in fast list mode Benjamin Marzinski
2018-02-12 20:33 ` Martin Wilck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1518466387.2761.62.camel@suse.com \
--to=mwilck@suse.com \
--cc=bmarzins@redhat.com \
--cc=dm-devel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.