* [PATCH] multipathd: fail path when path check timeout
@ 2016-08-10 8:10 tang.junhui
2016-10-11 6:50 ` tang.junhui
0 siblings, 1 reply; 5+ messages in thread
From: tang.junhui @ 2016-08-10 8:10 UTC (permalink / raw)
To: christophe varoqui; +Cc: zhang.kai16, dm-devel, tang.junhui
From: "tang.junhui" <tang.junhui@zte.com.cn>
path should be failed when path status is PATH_TIMEOUT after check,
otherwise, the valid number of paths in the map would be increased when
the path status is PATH_UP after the next turn check, which would cause
the valid number of paths exceeding the total number of paths in the map.
Signed-off-by: tang.junhui <tang.junhui@zte.com.cn>
---
multipathd/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/multipathd/main.c b/multipathd/main.c
index f5e9a01..01f1e58 100644
--- a/multipathd/main.c
+++ b/multipathd/main.c
@@ -1585,7 +1585,7 @@ check_path (struct vectors * vecs, struct path * pp, int ticks)
pp->checkint = conf->checkint;
put_multipath_config(conf);
- if (newstate == PATH_DOWN || newstate == PATH_SHAKY) {
+ if (newstate == PATH_DOWN || newstate == PATH_SHAKY || newstate == PATH_TIMEOUT) {
/*
* proactively fail path in the DM
*/
--
2.8.1.windows.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] multipathd: fail path when path check timeout
2016-08-10 8:10 [PATCH] multipathd: fail path when path check timeout tang.junhui
@ 2016-10-11 6:50 ` tang.junhui
2016-10-11 6:55 ` Christophe Varoqui
2016-10-12 2:54 ` Benjamin Marzinski
0 siblings, 2 replies; 5+ messages in thread
From: tang.junhui @ 2016-10-11 6:50 UTC (permalink / raw)
To: christophe.varoqui; +Cc: bart.vanassche, dm-devel, tang.junhui, zhang.kai16
[-- Attachment #1.1: Type: text/plain, Size: 1644 bytes --]
Please have a review for this patch, any comment will be highly
appreciated.
发件人: tang.junhui@zte.com.cn
收件人: christophe varoqui <christophe.varoqui@free.fr>,
抄送: dm-devel@redhat.com, zhang.kai16@zte.com.cn, "tang.junhui"
<tang.junhui@zte.com.cn>
日期: 2016/08/10 16:11
主题: [PATCH] multipathd: fail path when path check timeout
From: "tang.junhui" <tang.junhui@zte.com.cn>
path should be failed when path status is PATH_TIMEOUT after check,
otherwise, the valid number of paths in the map would be increased when
the path status is PATH_UP after the next turn check, which would cause
the valid number of paths exceeding the total number of paths in the map.
Signed-off-by: tang.junhui <tang.junhui@zte.com.cn>
---
multipathd/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/multipathd/main.c b/multipathd/main.c
index f5e9a01..01f1e58 100644
--- a/multipathd/main.c
+++ b/multipathd/main.c
@@ -1585,7 +1585,7 @@ check_path (struct vectors * vecs, struct path * pp,
int ticks)
pp->checkint = conf->checkint;
put_multipath_config(conf);
- if (newstate == PATH_DOWN || newstate ==
PATH_SHAKY) {
+ if (newstate == PATH_DOWN || newstate ==
PATH_SHAKY || newstate == PATH_TIMEOUT) {
/*
* proactively fail path
in the DM
*/
--
2.8.1.windows.1
[-- Attachment #1.2: Type: text/html, Size: 3330 bytes --]
[-- Attachment #2: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] multipathd: fail path when path check timeout
2016-10-11 6:50 ` tang.junhui
@ 2016-10-11 6:55 ` Christophe Varoqui
2016-10-12 2:54 ` Benjamin Marzinski
1 sibling, 0 replies; 5+ messages in thread
From: Christophe Varoqui @ 2016-10-11 6:55 UTC (permalink / raw)
To: tang.junhui; +Cc: Bart Van Assche, device-mapper development, zhang.kai16
[-- Attachment #1.1: Type: text/plain, Size: 1880 bytes --]
Merged.
Thanks.
On Tue, Oct 11, 2016 at 8:50 AM, <tang.junhui@zte.com.cn> wrote:
> Please have a review for this patch, any comment will be highly
> appreciated.
>
>
>
>
> 发件人: tang.junhui@zte.com.cn
> 收件人: christophe varoqui <christophe.varoqui@free.fr>,
> 抄送: dm-devel@redhat.com, zhang.kai16@zte.com.cn, "tang.junhui" <
> tang.junhui@zte.com.cn>
> 日期: 2016/08/10 16:11
> 主题: [PATCH] multipathd: fail path when path check timeout
> ------------------------------
>
>
>
> From: "tang.junhui" <tang.junhui@zte.com.cn>
>
> path should be failed when path status is PATH_TIMEOUT after check,
> otherwise, the valid number of paths in the map would be increased when
> the path status is PATH_UP after the next turn check, which would cause
> the valid number of paths exceeding the total number of paths in the map.
>
> Signed-off-by: tang.junhui <tang.junhui@zte.com.cn>
> ---
> multipathd/main.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/multipathd/main.c b/multipathd/main.c
> index f5e9a01..01f1e58 100644
> --- a/multipathd/main.c
> +++ b/multipathd/main.c
> @@ -1585,7 +1585,7 @@ check_path (struct vectors * vecs, struct path * pp,
> int ticks)
> pp->checkint = conf->checkint;
> put_multipath_config(conf);
>
> - if (newstate == PATH_DOWN || newstate
> == PATH_SHAKY) {
> + if (newstate == PATH_DOWN || newstate
> == PATH_SHAKY || newstate == PATH_TIMEOUT) {
> /*
> * proactively fail
> path in the DM
> */
> --
> 2.8.1.windows.1
>
>
>
[-- Attachment #1.2: Type: text/html, Size: 3576 bytes --]
[-- Attachment #2: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] multipathd: fail path when path check timeout
2016-10-11 6:50 ` tang.junhui
2016-10-11 6:55 ` Christophe Varoqui
@ 2016-10-12 2:54 ` Benjamin Marzinski
2016-10-12 3:20 ` tang.junhui
1 sibling, 1 reply; 5+ messages in thread
From: Benjamin Marzinski @ 2016-10-12 2:54 UTC (permalink / raw)
To: tang.junhui; +Cc: dm-devel, zhang.kai16, bart.vanassche
On Tue, Oct 11, 2016 at 02:50:00PM +0800, tang.junhui@zte.com.cn wrote:
> Please have a review for this patch, any comment will be highly
> appreciated.
This is clearly correct. I suspect that there will be other places where
we need to also check for PATH_TIMEOUT, since it is basically the same
as PATH_DOWN, except with a different state name. For instance, we
only log error messages on repeated checks for (newstate == PATH_DOWN),
and we should probably do that for PATH_TIMEOUT as well. There are
probably more instances outside of check_path.
-Ben
>
> ������: tang.junhui@zte.com.cn
> �ռ���: christophe varoqui <christophe.varoqui@free.fr>,
> ����: dm-devel@redhat.com, zhang.kai16@zte.com.cn, "tang.junhui"
> <tang.junhui@zte.com.cn>
> ����: 2016/08/10 16:11
> ����: [PATCH] multipathd: fail path when path check timeout
>
> --------------------------------------------------------------------------
>
> From: "tang.junhui" <tang.junhui@zte.com.cn>
>
> path should be failed when path status is PATH_TIMEOUT after check,
> otherwise, the valid number of paths in the map would be increased when
> the path status is PATH_UP after the next turn check, which would cause
> the valid number of paths exceeding the total number of paths in the map.
>
> Signed-off-by: tang.junhui <tang.junhui@zte.com.cn>
> ---
> multipathd/main.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/multipathd/main.c b/multipathd/main.c
> index f5e9a01..01f1e58 100644
> --- a/multipathd/main.c
> +++ b/multipathd/main.c
> @@ -1585,7 +1585,7 @@ check_path (struct vectors * vecs, struct path * pp,
> int ticks)
> pp->checkint = conf->checkint;
> put_multipath_config(conf);
>
> - if (newstate == PATH_DOWN || newstate
> == PATH_SHAKY) {
> + if (newstate == PATH_DOWN || newstate
> == PATH_SHAKY || newstate == PATH_TIMEOUT) {
> /*
> * proactively fail
> path in the DM
> */
> --
> 2.8.1.windows.1
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] multipathd: fail path when path check timeout
2016-10-12 2:54 ` Benjamin Marzinski
@ 2016-10-12 3:20 ` tang.junhui
0 siblings, 0 replies; 5+ messages in thread
From: tang.junhui @ 2016-10-12 3:20 UTC (permalink / raw)
To: Benjamin Marzinski; +Cc: dm-devel, zhang.kai16, bart.vanassche
[-- Attachment #1.1: Type: text/plain, Size: 3103 bytes --]
Hello, Ben
Thanks for your review,
This problem is found by our automatic testing,
I will spend more time to correct other similar bugs in the next patch。
Cheers,
Tang
发件人: "Benjamin Marzinski" <bmarzins@redhat.com>
收件人: tang.junhui@zte.com.cn,
抄送: dm-devel@redhat.com, zhang.kai16@zte.com.cn,
bart.vanassche@sandisk.com
日期: 2016/10/12 11:02
主题: Re: [dm-devel] [PATCH] multipathd: fail path when path check
timeout
发件人: dm-devel-bounces@redhat.com
On Tue, Oct 11, 2016 at 02:50:00PM +0800, tang.junhui@zte.com.cn wrote:
> Please have a review for this patch, any comment will be highly
> appreciated.
This is clearly correct. I suspect that there will be other places where
we need to also check for PATH_TIMEOUT, since it is basically the same
as PATH_DOWN, except with a different state name. For instance, we
only log error messages on repeated checks for (newstate == PATH_DOWN),
and we should probably do that for PATH_TIMEOUT as well. There are
probably more instances outside of check_path.
-Ben
>
> ������: tang.junhui@zte.com.cn
> �ռ���: christophe varoqui <christophe.varoqui@free.fr>,
> ����: dm-devel@redhat.com, zhang.kai16@zte.com.cn,
"tang.junhui"
> <tang.junhui@zte.com.cn>
> ����: 2016/08/10 16:11
> ����: [PATCH] multipathd: fail path when path check
timeout
>
>
--------------------------------------------------------------------------
>
> From: "tang.junhui" <tang.junhui@zte.com.cn>
>
> path should be failed when path status is PATH_TIMEOUT after check,
> otherwise, the valid number of paths in the map would be increased
when
> the path status is PATH_UP after the next turn check, which would
cause
> the valid number of paths exceeding the total number of paths in the
map.
>
> Signed-off-by: tang.junhui <tang.junhui@zte.com.cn>
> ---
> multipathd/main.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/multipathd/main.c b/multipathd/main.c
> index f5e9a01..01f1e58 100644
> --- a/multipathd/main.c
> +++ b/multipathd/main.c
> @@ -1585,7 +1585,7 @@ check_path (struct vectors * vecs, struct path
* pp,
> int ticks)
> pp->checkint = conf->checkint;
> put_multipath_config(conf);
>
> - if (newstate == PATH_DOWN ||
newstate
> == PATH_SHAKY) {
> + if (newstate == PATH_DOWN ||
newstate
> == PATH_SHAKY || newstate == PATH_TIMEOUT) {
> /*
> * proactively
fail
> path in the DM
> */
> --
> 2.8.1.windows.1
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
[-- Attachment #1.2: Type: text/html, Size: 5757 bytes --]
[-- Attachment #2: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2016-10-12 3:20 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-10 8:10 [PATCH] multipathd: fail path when path check timeout tang.junhui
2016-10-11 6:50 ` tang.junhui
2016-10-11 6:55 ` Christophe Varoqui
2016-10-12 2:54 ` Benjamin Marzinski
2016-10-12 3:20 ` tang.junhui
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.