multipathd: don't update priority of failed paths
authorBenjamin Marzinski <bmarzins@redhat.com>
Mon, 27 Feb 2017 18:26:40 +0000 (12:26 -0600)
committerChristophe Varoqui <christophe.varoqui@opensvc.com>
Mon, 27 Feb 2017 20:40:39 +0000 (21:40 +0100)
Multipathd shouldn't be updating the priority of failed paths in the
checkerloop. The current avoids this in almost all cases, but not all.
Close the loophole.

Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
multipathd/main.c

index 0f32b2c..553d1d1 100644 (file)
@@ -1467,7 +1467,8 @@ int update_prio(struct path *pp, int refresh_all)
        }
        oldpriority = pp->priority;
        conf = get_multipath_config();
-       pathinfo(pp, conf, DI_PRIO);
+       if (pp->state != PATH_DOWN)
+               pathinfo(pp, conf, DI_PRIO);
        put_multipath_config(conf);
 
        if (pp->priority == oldpriority)