Bug 928996 - Determine which LVM device types can be stacked, in which order.
Summary: Determine which LVM device types can be stacked, in which order.
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: lvm2
Version: 7.0
Hardware: All
OS: Linux
Target Milestone: beta
: ---
Assignee: LVM and device-mapper development team
QA Contact: cluster-qe@redhat.com
: 928997 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 2013-03-28 23:57 UTC by Tom Coughlan
Modified: 2021-09-08 20:41 UTC (History)
12 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2016-11-04 04:06:22 UTC
Target Upstream Version:

Attachments (Terms of Use)
results (13.69 KB, text/plain)
2016-09-13 11:07 UTC, Roman Bednář
no flags Details

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1445 0 normal SHIPPED_LIVE lvm2 bug fix and enhancement update 2016-11-03 13:46:41 UTC

Description Tom Coughlan 2013-03-28 23:57:30 UTC
LVM has recently added several new device types based on dm-raid, thinp, thin snap, (and soon) dm-cache. These are in addition to linear, stripe, mirror. We also have crypt, multipath, and md outside LVM.  

We need to specify which combinations of these device types are allowed to be stacked, and in which order. Additional factors, like external origins, metadata, and log devices must be considered.  

Code may be required to disallow unsupported combinations.

Instructions for how to properly create these stacked devices needs to be included in the LVM documentation. 

Full testing of the allowed combinations needs to be included in the QE plan.

Comment 2 Zdenek Kabelac 2013-05-14 08:45:10 UTC
*** Bug 928997 has been marked as a duplicate of this bug. ***

Comment 3 Ludek Smid 2014-06-26 10:45:47 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.

Comment 4 Ludek Smid 2014-06-26 11:14:03 UTC
The comment above is incorrect. The correct version is bellow.
I'm sorry for any inconvenience.

This request was NOT resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you need
to escalate this bug.

Comment 6 Jonathan Earl Brassow 2015-04-09 22:51:12 UTC
This is - to a degree - a documentation issue.  Perhaps there are some checks that could be done during creation to prevent inappropriate stacking.

Comment 8 Jonathan Earl Brassow 2016-01-19 00:15:24 UTC
Marian has made some good progress on this and produced a document that is ready to be reviewed by the doc team and then posted in the knowledge base.  CC'ing slevine on this bug so he's aware.

Comment 10 Marian Csontos 2016-06-30 07:59:57 UTC
The document has been published. Awaiting more comments.

What next?

Shall we link it from Documentation?

I will add link from lvm site.

Comment 11 Jonathan Earl Brassow 2016-08-25 15:10:28 UTC
Document is present on our customer portal:

We should also take care to update this document as things change in the future (e.g. for dm-integrity).

Comment 13 Roman Bednář 2016-09-13 11:06:45 UTC
Marking as verified after document revision and testing the stacking as shown in this matrix https://access.redhat.com/articles/2106521#matrix

Adding attachment with more detailed results of testing.

X/Y			X/Linear	X/Stripe	X/Mirror		
Pool Meta/Y		OK – verified	OK – verified	-			
Pool Data/Y		OK – verified	OK – verified	-		
Ext.Ori for Thin S./Y	OK – verified	OK – verified	OK – verified	
Ori. for Old S./Y	OK – verified	OK – verified	OK – verified	
Cache Data/Y		OK – verified	OK – verified	-		
Cache Meta/Y		OK – verified	OK – verified	-		
Cache Origin/Y		OK – verified	OK – verified	-		
X/RAIDn		X/Thin Volume	X/Old Snapshot	X/Cache Volume
Preferred	-		-		-
OK – verified	-		-		OK!– verified
OK – verified	OK – verified	-		-
OK – verified	OK – verified	-		-
OK!– verified	-	-	-		-
OK!– verified	-	-	-		-
OK – verified	MAYBE	-	-		TODO

Old snap of mirror is not actually recommended (type raid1 is).
Command warns user when legacy mirror is used explicitly:
# lvs -a -o lv_name,lv_attr,pool_lv,origin,devices
  LV                   Attr        Devices                                                          
  mirror_lv            mwi-a-m---  mirror_lv_mimage_0(0),mirror_lv_mimage_1(0),mirror_lv_mimage_2(0)
  [mirror_lv_mimage_0] Iwi-aom---  /dev/sda(0)                                                      
  [mirror_lv_mimage_1] Iwi-aom---  /dev/sdb(0)                                                      
  [mirror_lv_mimage_2] Iwi-aom---  /dev/sdc(0)                                                      
  [mirror_lv_mlog]     lwi-aom---  /dev/sdj(0)                                                      

# lvcreate -s vg/mirror_lv -L 1G
  Using default stripesize 64.00 KiB.
  WARNING: Snapshots of mirrors can deadlock under rare device failures.
  WARNING: Consider using the raid1 mirror type to avoid this.
  WARNING: See global/mirror_segtype_default in lvm.conf.
  mirror_lv must be active exclusively to create snapshot
Perhaps it would be worth mentioning in the new documentation, just for completeness?

Comment 14 Roman Bednář 2016-09-13 11:07:53 UTC
Created attachment 1200468 [details]

Comment 16 errata-xmlrpc 2016-11-04 04:06:22 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.