Bug 201935 - lvm "--alloc anywhere" hint is worthless with mirrors
Summary: lvm "--alloc anywhere" hint is worthless with mirrors
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: lvm2
Version: 4.0
Hardware: All
OS: Linux
medium
low
Target Milestone: ---
: ---
Assignee: Jonathan Earl Brassow
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-08-09 20:46 UTC by Corey Marthaler
Modified: 2009-05-18 20:10 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-05-18 20:10:32 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2009:0967 0 normal SHIPPED_LIVE lvm2 bug-fix and enhancement update 2009-05-18 13:33:39 UTC

Description Corey Marthaler 2006-08-09 20:46:21 UTC
Description of problem:
This kind of has to do with bz 164585. If I don't have enough pvs (one more than
the desired number of legs) in my volume group, lvm doesn't let me create a
mirror and in doing so tells me to "Consider --alloc anywhere if desperate."
That flag doesn't acutally let you create the mirror you are requesting and is
basically worthless and frustrating to the user.

[root@link-08 ~]# pvscan
  PV /dev/sda1   VG mirror   lvm2 [135.66 GB / 135.66 GB free]
  PV /dev/sdb1   VG mirror   lvm2 [135.66 GB / 135.66 GB free]
[root@link-08 ~]# lvcreate -m 1 -L 100K mirror
  Rounding up size to full physical extent 4.00 MB
  Not enough PVs with free space available for parallel allocation.
  Consider --alloc anywhere if desperate.
[root@link-08 ~]# lvcreate -m 1 -L 100K --alloc anywhere mirror
  Rounding up size to full physical extent 4.00 MB
  Insufficient suitable allocatable extents for logical volume : 2 more required

[root@link-08 ~]# pvscan
  PV /dev/sda1   VG mirror   lvm2 [135.66 GB / 135.66 GB free]
  PV /dev/sdb1   VG mirror   lvm2 [135.66 GB / 135.66 GB free]
  PV /dev/sdc1   VG mirror   lvm2 [135.66 GB / 135.66 GB free]
[root@link-08 ~]# lvcreate -m 2 -L 100M  mirror
  Not enough PVs with free space available for parallel allocation.
  Consider --alloc anywhere if desperate.
[root@link-08 ~]# lvcreate -m 2 -L 100M --alloc anywhere mirror
  Insufficient suitable allocatable extents for logical volume : 75 more required
[root@link-08 ~]# lvcreate -m 2 -L 1M --alloc anywhere mirror
  Rounding up size to full physical extent 4.00 MB
  Insufficient suitable allocatable extents for logical volume : 3 more required
[root@link-08 ~]# lvcreate -m 2 -L 100K --alloc anywhere mirror
  Rounding up size to full physical extent 4.00 MB
  Insufficient suitable allocatable extents for logical volume : 3 more required


Version-Release number of selected component (if applicable):
[root@link-08 ~]# rpm -q lvm2
lvm2-2.02.06-6.0.RHEL4


How reproducible:
everytime

Comment 1 Jonathan Earl Brassow 2008-10-21 19:14:26 UTC
I don't recall exactly when this got fixed, but it is fixed.


[root@bp-xen-05 ~]# vgs
  VG         #PV #LV #SN Attr   VSize   VFree
  VolGroup00   1   2   0 wz--n-   7.88G      0
  vg           2   0   0 wz--nc 233.76G 233.76G
[root@bp-xen-05 ~]# lvcreate -m1 -L 500M -n lv vg
  Insufficient suitable allocatable extents for logical volume : 125 more required
  Unable to allocate extents for mirror(s).
[root@bp-xen-05 ~]# lvcreate -m1 -L 500M -n lv vg --alloc anywhere
  Logical volume "lv" created
[root@bp-xen-05 ~]# lvs -a -o +devices
  LV            VG         Attr   LSize   Origin Snap%  Move Log     Copy%  Convert Devices                 
  LogVol00      VolGroup00 -wi-ao   5.84G                                           /dev/xvda2(0)           
  LogVol01      VolGroup00 -wi-ao   2.03G                                           /dev/xvda2(187)         
  lv            vg         mwa-a- 500.00M                    lv_mlog  28.80         lv_mimage_0(0),lv_mimage_1(0)
  [lv_mimage_0] vg         Iwi-ao 500.00M                                           /dev/xvdb1(0)           
  [lv_mimage_1] vg         Iwi-ao 500.00M                                           /dev/xvdc1(0)           
  [lv_mlog]     vg         lwa-ao   4.00M                                           /dev/xvdb1(125)

Comment 3 Milan Broz 2008-12-16 16:54:16 UTC
In CVS - lvm2-2.02.42-1.el4

Comment 5 Corey Marthaler 2009-04-20 21:16:10 UTC
Fix verified in lvm2-2.02.42-5.el4, though I'm not sure where the "Not enough PVs with free space" message went, that one was actually helpful.

Comment 7 errata-xmlrpc 2009-05-18 20:10:32 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2009-0967.html


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