libmultipath: sync_map_state: log failing paths
authorMartin Wilck <mwilck@suse.com>
Fri, 2 Nov 2018 12:21:24 +0000 (13:21 +0100)
committerChristophe Varoqui <christophe.varoqui@opensvc.com>
Wed, 14 Nov 2018 07:21:50 +0000 (08:21 +0100)
Emit a log message when force-failing exisiting paths.

Reviewed-by: Benjamin Marzinski <bmarzins@redhat.com>
Signed-off-by: Martin Wilck <mwilck@suse.com>
libmultipath/structs_vec.c

index f87d69d..c85823a 100644 (file)
@@ -318,8 +318,11 @@ sync_map_state(struct multipath *mpp)
                        else if ((pp->dmstate == PSTATE_ACTIVE ||
                                  pp->dmstate == PSTATE_UNDEF) &&
                                 (pp->state == PATH_DOWN ||
-                                 pp->state == PATH_SHAKY))
+                                 pp->state == PATH_SHAKY)) {
+                               condlog(2, "sync_map_state: failing %s state %d dmstate %d",
+                                       pp->dev, pp->state, pp->dmstate);
                                dm_fail_path(mpp->alias, pp->dev_t);
+                       }
                }
        }
 }