Bug 734193
Summary: | divisibility issues when attempting to create striped mirrors | |||
---|---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | Corey Marthaler <cmarthal> | |
Component: | lvm2 | Assignee: | Petr Rockai <prockai> | |
Status: | CLOSED ERRATA | QA Contact: | Corey Marthaler <cmarthal> | |
Severity: | medium | Docs Contact: | ||
Priority: | medium | |||
Version: | 6.1 | CC: | agk, coughlan, dwysocha, heinzm, jbrassow, mbroz, prajnoha, prockai, thornber, zkabelac | |
Target Milestone: | rc | |||
Target Release: | --- | |||
Hardware: | x86_64 | |||
OS: | Linux | |||
Whiteboard: | ||||
Fixed In Version: | lvm2-2.02.87-3.el6 | Doc Type: | Bug Fix | |
Doc Text: |
When using striped mirrors, an improper and too restrictive divisibility requirements for extent count took effect. This might have ended up with a failure to create a striped mirror despite it was correct and possible. The condition that was checked counted in mirror and stripe count though only stripe count alone was satisfactory.
|
Story Points: | --- | |
Clone Of: | ||||
: | 749650 (view as bug list) | Environment: | ||
Last Closed: | 2011-12-06 17:02:50 UTC | Type: | --- | |
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: | ||||
Bug Blocks: | 743047, 749650 |
Description
Corey Marthaler
2011-08-29 17:07:26 UTC
In all the cases where the command fails (26, 50, 126, 150, 250) the number of extents is *not* divisible by 4, i.e. the request is rejected correctly. You apparently have 4M extents, i.e. a 100M volume would be 25 extents, which LVM tries to round to 26, which is however still not divisible by 4 (26/4 = 6.5) and fails. The nearest 4-divisible number is 28, resulting in a 112M volume (if I am reading your case correctly). As far as I can tell, it is sufficient to require 2-divisible number, i.e. 26 should pass, but the allocation code incorrectly accounts for the mirrors in addition to stripes. All the divisibility cases failing in the original report no longer fail in the latest rpms. 2.6.32-198.el6.x86_64 lvm2-2.02.87-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 lvm2-libs-2.02.87-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 lvm2-cluster-2.02.87-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 udev-147-2.38.el6 BUILT: Fri Sep 9 16:25:50 CDT 2011 device-mapper-1.02.66-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 device-mapper-libs-1.02.66-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 device-mapper-event-1.02.66-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 device-mapper-event-libs-1.02.66-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 cmirror-2.02.87-3.el6 BUILT: Wed Sep 21 09:54:55 CDT 2011 [root@grant-01 ~]# lvcreate -m 1 -i 2 -n striped_secondary_2legs_1 -L 100M helter_skelter /dev/sdb1:0-1000 /dev/sdb2:0-1000 /dev/sdb3:0-1000 /dev/sdb5:0-1000 /dev/sdb6:0-150 Using default stripesize 64.00 KiB Rounding size (25 extents) up to stripe boundary size (26 extents) Logical volume "striped_secondary_2legs_1" created [root@grant-01 ~]# lvcreate -m 1 -i 2 -n striped_secondary_2legs_2 -L 200M helter_skelter /dev/sdb1:0-1000 /dev/sdb2:0-1000 /dev/sdb3:0-1000 /dev/sdb5:0-1000 /dev/sdb6:0-150 Using default stripesize 64.00 KiB Logical volume "striped_secondary_2legs_2" created [root@grant-01 ~]# lvcreate -m 1 -i 2 -n striped_secondary_2legs_3 -L 500M helter_skelter /dev/sdb1:0-1000 /dev/sdb2:0-1000 /dev/sdb3:0-1000 /dev/sdb5:0-1000 /dev/sdb6:0-150 Using default stripesize 64.00 KiB Rounding size (125 extents) up to stripe boundary size (126 extents) Logical volume "striped_secondary_2legs_3" created [root@grant-01 ~]# lvcreate -m 1 -i 2 -n striped_secondary_2legs_4 -L 600M helter_skelter /dev/sdb1:0-1000 /dev/sdb2:0-1000 /dev/sdb3:0-1000 /dev/sdb5:0-1000 /dev/sdb6:0-150 Using default stripesize 64.00 KiB Logical volume "striped_secondary_2legs_4" created [root@grant-01 ~]# lvcreate -m 1 -i 2 -n striped_secondary_2legs_5 -L 1000M helter_skelter /dev/sdb1:0-1000 /dev/sdb2:0-1000 /dev/sdb3:0-1000 /dev/sdb5:0-1000 /dev/sdb6:0-150 Using default stripesize 64.00 KiB Logical volume "striped_secondary_2legs_5" created Two things here: The divisibility error was correct in that the divisibility that was requested was not met. It was not correct in that it was needlessly strict: it is sufficient to demand 2-divisibility (instead of 4-divisibility) in these cases. I have fixed the latter issue, meaning that the errors are gone because we no longer demand (superfluous) 4-divisibility. Marking verified based on comment #4 and comment #5. Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: When using striped mirrors, an improper and too restrictive divisibility requirements for extent count took effect. This might have ended up with a failure to create a striped mirror despite it was correct and possible. The condition that was checked counted in mirror and stripe count though only stripe count alone was satisfactory. 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. http://rhn.redhat.com/errata/RHBA-2011-1522.html |