Bug 1710551

Summary: "Unknown feature in status:" messages in lvs output
Product: Red Hat Enterprise Linux 8 Reporter: Corey Marthaler <cmarthal>
Component: lvm2Assignee: Zdenek Kabelac <zkabelac>
lvm2 sub component: Displaying and Reporting QA Contact: cluster-qe <cluster-qe>
Status: CLOSED NEXTRELEASE Docs Contact:
Severity: low    
Priority: unspecified CC: agk, cluster-qe, evansjahja13, heinzm, jbrassow, lvm-team, mcsontos, msnitzer, prajnoha, rhandlin, zkabelac
Version: 8.0Keywords: FutureFeature
Target Milestone: rc   
Target Release: 8.0   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: lvm2-2.03.04-1.el8 Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: 1706984 Environment:
Last Closed: 2019-08-21 18:27:56 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1706984    
Bug Blocks:    

Comment 1 Corey Marthaler 2019-05-15 18:19:08 UTC
This exists using lvm with the latest 8.1 kernel as well.

[root@hayes-01 ~]# lvs -a -o +devices
  Unknown feature in status: 8 208/3072 128 5892/65536 11836 50927 9041 21795 0 1709 0 2 writethrough no_discard_passdown 2 migration_threshold 2048 smq 0 rw - 
  Unknown feature in status: 8 208/3072 128 5892/65536 11836 50927 9041 21795 0 1709 0 2 writethrough no_discard_passdown 2 migration_threshold 2048 smq 0 rw - 
  LV                      VG           Attr       LSize  Pool          Origin                  Data%  Meta%  Move Log Cpy%Sync Convert Devices                 
  [block_cache]           cache_sanity Cwi---C---  4.00g                                       8.99   6.77            0.00             block_cache_cdata(0)    
  [block_cache_cdata]     cache_sanity Cwi-ao----  4.00g                                                                               /dev/sdh1(0)            
  [block_cache_cmeta]     cache_sanity ewi-ao---- 12.00m                                                                               /dev/sdh1(1024)         
  block_io_origin         cache_sanity owi-aoC--- 15.00g [block_cache] [block_io_origin_corig] 8.99   6.77            0.00             block_io_origin_corig(0)
  [block_io_origin_corig] cache_sanity owi-aoC--- 15.00g                                                                               /dev/sdd1(0)            
  block_snap16            cache_sanity swi-aos---  3.00g               block_io_origin         13.24                                   /dev/sdd1(3843)         
  [lvol0_pmspare]         cache_sanity ewi------- 12.00m                                                                               /dev/sdd1(3840)         


4.18.0-87.el8.x86_64

kernel-4.18.0-87.el8    BUILT: Mon May 13 12:40:49 CDT 2019

lvm2-2.03.02-6.el8    BUILT: Fri Feb 22 04:47:54 CST 2019
lvm2-libs-2.03.02-6.el8    BUILT: Fri Feb 22 04:47:54 CST 2019
lvm2-dbusd-2.03.02-6.el8    BUILT: Fri Feb 22 04:50:28 CST 2019
lvm2-lockd-2.03.02-6.el8    BUILT: Fri Feb 22 04:47:54 CST 2019
device-mapper-1.02.155-6.el8    BUILT: Fri Feb 22 04:47:54 CST 2019
device-mapper-libs-1.02.155-6.el8    BUILT: Fri Feb 22 04:47:54 CST 2019
device-mapper-event-1.02.155-6.el8    BUILT: Fri Feb 22 04:47:54 CST 2019
device-mapper-event-libs-1.02.155-6.el8    BUILT: Fri Feb 22 04:47:54 CST 2019
device-mapper-persistent-data-0.7.6-1.el8    BUILT: Sun Aug 12 04:21:55 CDT 2018

Comment 2 Zdenek Kabelac 2019-05-16 08:13:48 UTC
Seems the kernel has been 'enhanced'  with new reported feature  'no_discard_passdown' - and lvm2 doens't know about it yet.

So it reports the 'unknown' feature.

Patch is needed to enhance libdm API to understand (and report) this bit of info.

Requires relatively 'low amount' of work to fix this - but it's not a one-liner patch.

If the lvm2 should also support setting this feature - it's a further enhancement.

Comment 3 Mike Snitzer 2019-06-03 15:59:24 UTC
I assume 'no_discard_passdown' got set as a side-effect of the underlying origin device not supporting discards. 

As for missing the need to support this feature.. sorry:

commit de7180ff908b2bc0342e832dbdaa9a5f1ecaa33a
Author: Mike Snitzer <snitzer>
Date:   Mon Feb 25 11:07:10 2019 -0500

    dm cache: add support for discard passdown to the origin device

    DM cache now defaults to passing discards down to the origin device.
    User may disable this using the "no_discard_passdown" feature when
    creating the cache device.

    If the cache's underlying origin device doesn't support discards then
    passdown is disabled (with warning).  Similarly, if the underlying
    origin device's max_discard_sectors is less than a cache block discard
    passdown will be disabled (this is required because sizing of the cache
    internal discard bitset depends on it).

    Signed-off-by: Mike Snitzer <snitzer>

Comment 4 Zdenek Kabelac 2019-06-05 13:59:50 UTC
Upstream commit into stable branch  enhances lvm to report new field and understand report feature:


lvs -o+kernel-discards   will show if no_discard_passdown is present as  'nopassdown'


Associated test-case:

https://www.redhat.com/archives/lvm-devel/2019-June/msg00008.html

Comment 5 Zdenek Kabelac 2019-06-05 14:36:14 UTC
Actually the patch reference of the fixing commit is missing in comment 4:

stable branch 2.02/RH7.7:

https://www.redhat.com/archives/lvm-devel/2019-June/msg00006.html


Cherry-pick of upstream master commit:

https://www.redhat.com/archives/lvm-devel/2019-June/msg00003.html

Comment 6 Marian Csontos 2019-06-20 18:07:05 UTC
This is already fixed in version included in rhel-8.1