From: Zdenek Kabelac <zdenek.kabelac@gmail.com>
To: LVM general discussion and development <linux-lvm@redhat.com>,
"heming.zhao@suse.com" <heming.zhao@suse.com>
Cc: teigland@sourceware.org, zkabelac@redhat.com
Subject: Re: [linux-lvm] [PATCH] lvs: add -o lv_usable
Date: Mon, 7 Sep 2020 16:32:47 +0200 [thread overview]
Message-ID: <53a24f12-9f5e-535d-bf80-83b9db9259c6@gmail.com> (raw)
In-Reply-To: <6b1c4f75-37ee-caa9-623a-363a8e791e4d@suse.com>
Dne 05. 09. 20 v 11:08 heming.zhao@suse.com napsal(a):
>
>
> On 9/5/20 5:06 PM, Zhao Heming wrote:
>> report LV is usable for upper layer.
>>
>> Signed-off-by: Zhao Heming <heming.zhao@suse.com>
>> ---
>> lib/activate/activate.h | 2 +
>> lib/activate/dev_manager.c | 67 ++++++++++++++++
>> lib/metadata/metadata-exported.h | 1 +
>> lib/metadata/metadata.c | 130 +++++++++++++++++++++++++++++++
>> lib/report/columns.h | 1 +
>> lib/report/properties.c | 2 +
>> lib/report/report.c | 13 ++++
>> lib/report/values.h | 1 +
>> 8 files changed, 217 insertions(+)
>>
>
> my test result:
>
> ## linear
>
Hi
We will need to take closer look - the patchset itself is not going in right
direction - since all the info about missing or present devices is already
available within lvm engine and we want to minimize 'repeated' query
(ideally all the information should be checked only once - otherwise
the decision state-machine is producing random-end result garbage - which
is the very hard to trace and debug.
So all the code which is doing runtime query again can't be accepted.
Next main rule is - we cache status values whenever possible - so there
should be at most 1 'status' per device per LV - but since lvm2 already
knows from scanning point and from metadata parsing which device is missing
the logic of evaluation of LV's usability needs to be based on these values.
But I think we also need some per-segment methods evaluating usability.
Regards
Zdenek
next prev parent reply other threads:[~2020-09-07 14:32 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-05 9:06 [linux-lvm] [PATCH] lvs: add -o lv_usable Zhao Heming
2020-09-05 9:08 ` heming.zhao
2020-09-07 14:32 ` Zdenek Kabelac [this message]
2020-09-08 6:40 ` heming.zhao
2020-09-08 17:47 ` David Teigland
2020-09-05 9:17 ` heming.zhao
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53a24f12-9f5e-535d-bf80-83b9db9259c6@gmail.com \
--to=zdenek.kabelac@gmail.com \
--cc=heming.zhao@suse.com \
--cc=linux-lvm@redhat.com \
--cc=teigland@sourceware.org \
--cc=zkabelac@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).