dm mpath: only retry ioctl if queue_if_no_path was configured
On Sat, Sep 08 2012 at 12:50pm -0400,
Mikulas Patocka <firstname.lastname@example.org> wrote:
> It's hard to say what should be done correctly ... if you create a
> multipath device with "queue_if_no_path" and no active path, it should
> delay all requests until a path becomes available ... and it is doing
> Maybe we could move the waiting loop up to dm_blk_ioctl so that it unlocks
> when someone reloads the target?
I think it much more likely that multipathd will restore a path then an
entirely new table be loaded.
> BTW. there is also -EAGAIN dm_blk_ioctl if dm_suspended_md ... should this
> -EAGAIN be removed too or not?
Don't think it needs to be removed. Here is a patch that addresses the
issue for me.
From: Mike Snitzer <email@example.com>
Subject: [PATCH] dm mpath: only retry ioctl if queue_if_no_path was configured
commit 35991652b ("dm mpath: allow ioctls to trigger pg init") should
have checked if queue_if_no_path was configured before queueing IO.
Checking for the queue_if_no_path feature, like is done in map_io(),
allows the following table load to work without blocking in the
multipath_ioctl retry loop: