Re: [dm-devel] [PATCH v4 00/11] Zoned block device support improvements

2018-10-25 Thread Jens Axboe
On 10/24/18 10:04 AM, Bart Van Assche wrote: > On Wed, 2018-10-24 at 11:37 -0400, Martin K. Petersen wrote: >> Mike, >> You keep mentioning this, but I don't recall ever seeing anything to that effect. The rest of the kernel appears to be either arbitrary ordering or favoring author

Re: [dm-devel] [RFC] dm-bow working prototype

2018-10-25 Thread Paul Lawrence
Thank you for the suggestion. I spent part of yesterday experimenting with this idea, and it is certainly very promising. However, it does have some disadvantages as compared to dm-bow, if I am understanding the setup correctly: 1) Since dm-snap has no concept of the free space on the

Re: [dm-devel] [PATCH 06/21] libmultipath/checkers: emc_clariion: use message id

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:52AM +0200, Martin Wilck wrote: > emc_clariion is the only path checker that was using a non-constant > message ("read error" case). This isn't possible with the msgid > approach any more. Use condlog() for the dynamic log message and > simply report "read error" as

Re: [dm-devel] [PATCH 07/21] libmultipath/checkers: hp_sw: use message id

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:53AM +0200, Martin Wilck wrote: Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/checkers/hp_sw.c | 12 > 1 file changed, 4 insertions(+), 8 deletions(-) > > diff --git a/libmultipath/checkers/hp_sw.c

Re: [dm-devel] [PATCH 08/21] libmultipath/checkers: rdac: use message id

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:54AM +0200, Martin Wilck wrote: Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/checkers/rdac.c | 64 +--- > 1 file changed, 45 insertions(+), 19 deletions(-) > > diff --git

Re: [dm-devel] [RFC] dm-bow working prototype

2018-10-25 Thread Wols Lists
On 25/10/18 19:13, Paul Lawrence wrote: >> I have some questions about dm-bow: >> – How file system agnostic this feature is planned to be? While it is >> designed with ext4 in mind, is it going to work when used over other >> file systems, like FAT or BTRFS for example? > So long as the file

Re: [dm-devel] [PATCH 01/21] libmultipath: fix use of uninitialized memory in write()

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:47AM +0200, Martin Wilck wrote: > valgrind complained about this. > Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/discovery.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git

Re: [dm-devel] [PATCH 02/21] libmultipath: fix memory leaks from scandir() use

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:48AM +0200, Martin Wilck wrote: > scandir() users must not only free the resulting dirent* array, > but also every member. Add a cleanup function, and fix the > existing users of scandir() in libmultipath. > > Add a small helper macro for casting function pointers to

Re: [dm-devel] [PATCH 10/21] libmultipath/checkers: tur: use message id

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:56AM +0200, Martin Wilck wrote: Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/checkers/tur.c | 54 - > 1 file changed, 30 insertions(+), 24 deletions(-) > > diff --git

Re: [dm-devel] [RFC] dm-bow working prototype

2018-10-25 Thread Darrick J. Wong
On Tue, Oct 23, 2018 at 02:23:28PM -0700, Paul Lawrence wrote: > bow == backup on write > > Similar to dm-snap, add the ability to take a snapshot of a device. > Unlike dm-snap, a separate volume is not required. > > dm-bow can be in one of three states. > > In state one, the free blocks on the

Re: [dm-devel] [PATCH 21/21] libmultipath/checkers: cleanup class/instance model

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:07AM +0200, Martin Wilck wrote: > The checkers code implicitly uses a sort-of OOP class/instance model, > but very clumsily. Separate the checker "class" and "instance" cleanly, > and do a few further cleanups (constifications etc) on the way. > Reviewed-by:

Re: [dm-devel] [PATCH 17/21] libmultipath: pathinfo: don't blank wwid if checker fails

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:03AM +0200, Martin Wilck wrote: > Blanking a WWID is a dangerous operation. E.g. configure() would > consider the path in question as invalid and orphan it if the > WWID is blank. Don't do this for possibly transient checker failures. > Moreover, we try to determine

Re: [dm-devel] [PATCH 18/21] multipathd: check_path: improve logging for "unusable path" case

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:04AM +0200, Martin Wilck wrote: Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > multipathd/main.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/multipathd/main.c b/multipathd/main.c > index 1bd1518a..8ce72fce

Re: [dm-devel] [PATCH 20/21] libmultipath: sync_map_state: log failing paths

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:06AM +0200, Martin Wilck wrote: > Emit a log message when force-failing exisiting paths. > Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/structs_vec.c | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff

Re: [dm-devel] [PATCH 03/21] libmultipath/checkers: replace message by msgid

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:49AM +0200, Martin Wilck wrote: > Replace the character array "message" in struct checker with > a "message ID" field. > > The generic checker code defines a couple of standard message IDs > and corresponding messages. Checker-specific message IDs start > at

Re: [dm-devel] [PATCH 12/21] libmultipath/checkers: support unsupported paths

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:58AM +0200, Martin Wilck wrote: > We should be able to distinguish the case where a checker > determines a path to be positively down from the case where > the checker fails to obtain necessary information, e.g. > because of a configuration problem (wrong checker). >

Re: [dm-devel] [PATCH 16/21] libmultipath: tur checker: leave unsupported paths alone

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:02AM +0200, Martin Wilck wrote: > A checker shouldn't set the path state to PATH_DOWN if it fails > to obtain information about the path in the first place. Add logic > to the checker to distinguish a failed path from an unsupported path. > Reviewed-by: Benjamin

Re: [dm-devel] [PATCH 14/21] libmultipath: hp_sw checker: leave unsupported paths alone

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:00AM +0200, Martin Wilck wrote: > A checker shouldn't set the path state to PATH_DOWN if it fails > to obtain information about the path in the first place. Add logic > to the checker to distinguish a failed path from an unsupported path. > Reviewed-by: Benjamin

Re: [dm-devel] [PATCH 04/21] libmultipath/checkers: cciss_tur: use message id

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:50AM +0200, Martin Wilck wrote: Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/checkers/cciss_tur.c | 13 + > 1 file changed, 5 insertions(+), 8 deletions(-) > > diff --git a/libmultipath/checkers/cciss_tur.c >

Re: [dm-devel] [PATCH 09/21] libmultipath/checkers: readsector0: use message id

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:55AM +0200, Martin Wilck wrote: Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/checkers/readsector0.c | 7 ++- > 1 file changed, 2 insertions(+), 5 deletions(-) > > diff --git a/libmultipath/checkers/readsector0.c >

Re: [dm-devel] [PATCH 11/21] multipathd: improve checker message logging

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:26:57AM +0200, Martin Wilck wrote: > Don't rely on any variables being defined in LOG_MSG. > If message log level is low, don't bother to fetch the message. > Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > multipathd/main.c | 34

Re: [dm-devel] [PATCH 03/21] libmultipath/checkers: replace message by msgid

2018-10-25 Thread Martin Wilck
On Thu, 2018-10-25 at 15:57 -0500, Benjamin Marzinski wrote: > On Fri, Oct 12, 2018 at 12:26:49AM +0200, Martin Wilck wrote: > > Replace the character array "message" in struct checker with > > a "message ID" field. > > > > The generic checker code defines a couple of standard message IDs > >

Re: [dm-devel] [PATCH 15/21] libmultipath: rdac checker: leave unsupported paths alone

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:01AM +0200, Martin Wilck wrote: > A checker shouldn't set the path state to PATH_DOWN if it fails > to obtain information about the path in the first place. Add logic > to the checker to distinguish a failed path from an unsupported path. > Reviewed-by: Benjamin

Re: [dm-devel] [PATCH 19/21] libmultipath: coalesce_paths: improve logging of orphaned paths

2018-10-25 Thread Benjamin Marzinski
On Fri, Oct 12, 2018 at 12:27:05AM +0200, Martin Wilck wrote: Reviewed-by: Benjamin Marzinski > Signed-off-by: Martin Wilck > --- > libmultipath/configure.c | 10 +++--- > 1 file changed, 7 insertions(+), 3 deletions(-) > > diff --git a/libmultipath/configure.c b/libmultipath/configure.c

Re: [dm-devel] [RFC] dm-bow working prototype

2018-10-25 Thread Paul Lawrence
The concept intrigued me, so I actually went on to try your prototype. I could apply it on v4.12 mainline (newer kernel versions introduce changes in "struct bio" in "include/linux/blk_types.h" those don't let the module compile – I think minor changes would be necessary to adapt to the new

[dm-devel] Vault '19 Submission Deadline Approaching

2018-10-25 Thread Ric Wheeler
Hi all, If anyone is interested in giving a talk at the open source storage conference - formerly hosted by the Linux Foundation, but now co-located with USENIX FAST - this first event in the new series will be in Boston next to FAST this coming year. It would be great to have a good showing

Re: [dm-devel] [RFC] dm-bow working prototype

2018-10-25 Thread Bryn M. Reeves
On Wed, Oct 24, 2018 at 03:24:29PM -0400, Mikulas Patocka wrote: > > > On Wed, 24 Oct 2018, Paul Lawrence wrote: > > > Android has had the concept of A/B updates for since Android N, which means > > that if an update is unable to boot for any reason three times, we revert to > > the older

Re: [dm-devel] dm writecache: remove unused variable sz in writecache_status

2018-10-25 Thread shenghui
On 10/25/2018 11:46 AM, Mike Snitzer wrote: > On Wed, Oct 24 2018 at 10:38pm -0400, > Shenghui Wang wrote: > >> sz defined but not used in writecache_status. Remove it. >> >> Signed-off-by: Shenghui Wang >> --- >> drivers/md/dm-writecache.c | 1 - >> 1 file changed, 1 deletion(-) >> >> diff

[dm-devel] [PATCH] dm writecache: flush metadata in single commit in init_memory

2018-10-25 Thread Shenghui Wang
Do not flush sb ->magic in second commit. Signed-off-by: Shenghui Wang --- drivers/md/dm-writecache.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/md/dm-writecache.c b/drivers/md/dm-writecache.c index d656bd1799ae..8e9e96a22f68 100644 ---

Re: [dm-devel] [PATCH] dm writecache: flush metadata in single commit in init_memory

2018-10-25 Thread shenghui
On 10/24/2018 10:38 PM, Mikulas Patocka wrote: > > > On Wed, 24 Oct 2018, Shenghui Wang wrote: > >> Do not flush sb ->magic in second commit. > > This is intentional. The magic is written last, so that if the machine > crashes while formatting the device, the incomplete superblock won't be

[dm-devel] [PATCH] dm writecache: remove unused variable sz in writecache_status

2018-10-25 Thread Shenghui Wang
sz defined but not used in writecache_status. Remove it. Signed-off-by: Shenghui Wang --- drivers/md/dm-writecache.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/md/dm-writecache.c b/drivers/md/dm-writecache.c index 5f1f80d424dd..562c32f644b8 100644 ---

[dm-devel] [PATCH] dm writecache: fix typo in error msg for creating writecache_flush_thread

2018-10-25 Thread Shenghui Wang
The error msg should be "flush thread" instead of "endio thread" for writecache_flush_thread. Signed-off-by: Shenghui Wang --- drivers/md/dm-writecache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/md/dm-writecache.c b/drivers/md/dm-writecache.c index