From: "heming.zhao@suse.com" <heming.zhao@suse.com>
To: David Teigland <teigland@redhat.com>
Cc: linux-lvm@redhat.com
Subject: Re: [linux-lvm] [PATCH] lvdisplay: dispaly correct status on linear type
Date: Thu, 27 Aug 2020 23:52:18 +0800 [thread overview]
Message-ID: <b509aa7c-777b-d925-e9c1-9493618d51f1@suse.com> (raw)
In-Reply-To: <20200826170320.GA11966@redhat.com>
thank you for your kindly review.
On 8/27/20 1:03 AM, David Teigland wrote:
> On Wed, Aug 26, 2020 at 11:50:44PM +0800, Zhao Heming wrote:
>> It commit is enhancement for 1d0dc74f9147e3c1f3681efa4166cbe2edcb6571
>> 1d0dc74f9147 only supports all raid type, this commit adds linear type.
>>
>> With this patch, for linear type LV, one of two disks missing,
>> lvdisplay will show
>> from:
>> LV Status available (partial)
>> to:
>> LV Status NOT available (partial)
>
> It would be nice if you could come up with a more formal definition for
> what you're calling "lv_is_available", and also in the same terms define
> the existing "lv_is_partial", explaining how they differ. Both properties
> may be useful to show in lvs reporting fields (and possibly lv_attr).
> Reporting this state only via the lvdisplay line above seems strange.
I will send the v2 patch very soon.
the v2 patch only for lvdisplay cmd. if my code acceptable, I plan update lvs
cmd in v3, add a new letter (N)ot_available in bit 9 (Volume Health).
>
>> + } else if (seg_type(seg, s) == AREA_PV) {
>> + if (seg_pv(seg, s)->status & MISSING_PV)
>
> Using only MISSING_PV is probably insufficient, because that flag is used
> only when the metadata is written while the device is missing. i.e.
> pv->dev can be NULL when the flag is not set.
>
I have a little confused with your comments.
These 2 lines are same as _lv_mark_if_partial_single() code:
```
if (seg_type(lvseg, s) == AREA_PV) {
if (is_missing_pv(seg_pv(lvseg, s))) {
```
why _lv_mark_if_partial_single can use these 2 lines?
please wait for the v2 patch, I changed some code logic, set the NOT_AVAIL_LV in
_lv_mark_if_partial_single().
> Dave
>
prev parent reply other threads:[~2020-08-27 15:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-26 15:50 [linux-lvm] [PATCH] lvdisplay: dispaly correct status on linear type Zhao Heming
2020-08-26 15:58 ` heming.zhao
2020-08-26 17:03 ` David Teigland
2020-08-27 15:52 ` heming.zhao [this message]
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=b509aa7c-777b-d925-e9c1-9493618d51f1@suse.com \
--to=heming.zhao@suse.com \
--cc=linux-lvm@redhat.com \
--cc=teigland@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 read-only IMAP folder(s) and NNTP newsgroup(s).