Bug 248449 - snap creation on inactive lv causes an invaild and "100% full" snapshot
snap creation on inactive lv causes an invaild and "100% full" snapshot
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: lvm2 (Show other bugs)
4.5
All Linux
low Severity low
: ---
: ---
Assigned To: Milan Broz
Corey Marthaler
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-07-16 16:33 EDT by Corey Marthaler
Modified: 2013-02-28 23:05 EST (History)
6 users (show)

See Also:
Fixed In Version: RHBA-2007-0753
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-11-15 10:58:54 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Proposed patch (979 bytes, patch)
2007-07-17 08:09 EDT, Milan Broz
no flags Details | Diff

  None (edit)
Description Corey Marthaler 2007-07-16 16:33:58 EDT
Description of problem:
[root@link-02 mnt]# vgcreate vg /dev/sd*1
  Volume group "vg" successfully created
[root@link-02 mnt]# lvcreate -n origin -L 5G vg
  Logical volume "origin" created
[root@link-02 mnt]# lvs -a -o +devices
  LV       VG         Attr   LSize  Origin Snap%  Move Log Copy%  Devices
  LogVol00 VolGroup00 -wi-ao 35.19G                               /dev/hda2(0)
  LogVol01 VolGroup00 -wi-ao  1.94G                               /dev/hda2(1126)
  origin   vg         -wi-a-  5.00G                               /dev/sda1(0)
[root@link-02 mnt]# lvcreate -s vg/origin -L 2G -n snap1
  Logical volume "snap1" created
[root@link-02 mnt]# lvs -a -o +devices
  LV       VG         Attr   LSize  Origin Snap%  Move Log Copy%  Devices
  LogVol00 VolGroup00 -wi-ao 35.19G                               /dev/hda2(0)
  LogVol01 VolGroup00 -wi-ao  1.94G                               /dev/hda2(1126)
  origin   vg         owi-a-  5.00G                               /dev/sda1(0)
  snap1    vg         swi-a-  2.00G origin   0.00                 /dev/sda1(1280)
[root@link-02 mnt]# lvchange -an vg/origin
[root@link-02 mnt]# lvs -a -o +devices
  LV       VG         Attr   LSize  Origin Snap%  Move Log Copy%  Devices
  LogVol00 VolGroup00 -wi-ao 35.19G                               /dev/hda2(0)
  LogVol01 VolGroup00 -wi-ao  1.94G                               /dev/hda2(1126)
  origin   vg         owi---  5.00G                               /dev/sda1(0)
  snap1    vg         swi---  2.00G origin                        /dev/sda1(1280)
[root@link-02 mnt]# vgsplit vg vg_newer /dev/sda1
  Volume group "vg_newer" successfully split from "vg"
[root@link-02 mnt]# lvs -a -o +devices
  LV       VG         Attr   LSize  Origin Snap%  Move Log Copy%  Devices
  LogVol00 VolGroup00 -wi-ao 35.19G                               /dev/hda2(0)
  LogVol01 VolGroup00 -wi-ao  1.94G                               /dev/hda2(1126)
  origin   vg_newer   owi---  5.00G                               /dev/sda1(0)
  snap1    vg_newer   swi---  2.00G origin                        /dev/sda1(1280)
[root@link-02 mnt]# lvcreate -s vg_newer/origin -L 2G -n snap4
  Logical volume "snap4" created
[root@link-02 mnt]# lvs -a -o +devices
  LV       VG         Attr   LSize  Origin Snap%  Move Log Copy%  Devices
  LogVol00 VolGroup00 -wi-ao 35.19G                               /dev/hda2(0)
  LogVol01 VolGroup00 -wi-ao  1.94G                               /dev/hda2(1126)
  origin   vg_newer   owi---  5.00G                               /dev/sda1(0)
  snap1    vg_newer   swi---  2.00G origin                        /dev/sda1(1280)
  snap4    vg_newer   Swi-I-  2.00G origin 100.00                 /dev/sda1(1792)

# Once it's re-activated, then it appears fine
[root@link-02 mnt]# lvchange -ay vg_newer/origin
[root@link-02 mnt]# lvs -a -o +devices
  LV       VG         Attr   LSize  Origin Snap%  Move Log Copy%  Devices
  LogVol00 VolGroup00 -wi-ao 35.19G                               /dev/hda2(0)
  LogVol01 VolGroup00 -wi-ao  1.94G                               /dev/hda2(1126)
  origin   vg_newer   owi-a-  5.00G                               /dev/sda1(0)
  snap1    vg_newer   swi-a-  2.00G origin   0.00                 /dev/sda1(1280)
  snap4    vg_newer   swi-a-  2.00G origin   0.00                 /dev/sda1(1792)



Version-Release number of selected component (if applicable):
2.6.9-55.8.ELsmp
lvm2-2.02.21-5.el4

How reproducible:
everytime
Comment 1 Milan Broz 2007-07-17 05:37:56 EDT
Reproduced, this is not vgsplit problem, any snapshot creation on inactive
logical volume create this invalid entry.

Temporary workaround is to use vgchange -a y after split.
Comment 2 Milan Broz 2007-07-17 08:09:08 EDT
Created attachment 159417 [details]
Proposed patch

Proposed patch
Comment 3 RHEL Product and Program Management 2007-07-17 08:25:06 EDT
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.
Comment 4 Milan Broz 2007-07-17 12:15:57 EDT
Fixed upstream in 2.02.27, this is regression introduced in 2.02.13.
Comment 7 Corey Marthaler 2007-07-27 14:50:58 EDT
fix verified in lvm2-2.02.27-1.el4.
Comment 9 errata-xmlrpc 2007-11-15 10:58:54 EST
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 the 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-2007-0753.html

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