Bug 481657 - vgsplit of base PV in stacked PV configuration causes problems
Summary: vgsplit of base PV in stacked PV configuration causes problems
Keywords:
Status: CLOSED DEFERRED
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: lvm2
Version: 5.3
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: LVM and device-mapper development team
QA Contact: Cluster QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-01-26 21:37 UTC by Corey Marthaler
Modified: 2011-10-21 16:11 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-10-21 16:11:48 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Corey Marthaler 2009-01-26 21:37:25 UTC
Description of problem:
I stacked PVs on top of existing LVs like so:

[root@hayes-03 ~]# pvscan
  PV /dev/etherd/e1.1p2    VG base2           lvm2 [1.77 TB / 1.77 TB free]
  PV /dev/etherd/e1.1p1    VG base1           lvm2 [1.77 TB / 1.77 TB free]
  PV /dev/base1/base_lv1   VG top             lvm2 [496.00 MB / 0    free]
  PV /dev/base2/base_lv2   VG top             lvm2 [496.00 MB / 192.00 MB

[root@hayes-03 ~]# lvs -a -o +devices
  LV       VG         Attr   LSize   Origin Snap%  Move Log Copy%  Convert Devices               
  base_lv1 base1      -wi-ao 500.00M                                       /dev/etherd/e1.1p1(0) 
  base_lv2 base2      -wi-ao 500.00M                                       /dev/etherd/e1.1p2(0) 
  top_lv   top        -wi-a- 800.00M                                       /dev/base1/base_lv1(0)
  top_lv   top        -wi-a- 800.00M                                       /dev/base2/base_lv2(0)

I then extended one of the base VGs, and deactivated the stack in order to split out a base PV:

[root@hayes-03 ~]# vgextend base1 /dev/etherd/e1.1p3
  Volume group "base1" successfully extended

[root@hayes-03 ~]# vgchange -an top
  0 logical volume(s) in volume group "top" now active
[root@hayes-03 ~]# lvchange -an base1/base_lv1
[root@hayes-03 ~]# vgsplit base1 base3 /dev/etherd/e1.1p1 
  New volume group "base3" successfully split from "base1"

But now, LVM is confused and doesn't know where to find it's base pv:

[root@hayes-03 ~]# pvscan
  Couldn't find device with uuid 'ie2zLM-30XY-bdfb-keJi-1xqi-NCwx-G03Bmh'.
  PV /dev/etherd/e1.1p3    VG base1           lvm2 [1.77 TB / 1.77 TB free]
  PV /dev/etherd/e1.1p2    VG base2           lvm2 [1.77 TB / 1.77 TB free]
  PV /dev/etherd/e1.1p1    VG base3           lvm2 [1.77 TB / 1.77 TB free]
  PV unknown device        VG top             lvm2 [496.00 MB / 0    free]
  PV /dev/base2/base_lv2   VG top             lvm2 [496.00 MB / 192.00 MB free]
  PV /dev/sda2             VG VolGroup00      lvm2 [74.38 GB / 0    free]
  PV /dev/etherd/e1.1p4                       lvm2 [1.77 TB]
  PV /dev/etherd/e1.1p5                       lvm2 [1.77 TB]


Version-Release number of selected component (if applicable):
2.6.18-128.el5

lvm2-2.02.40-6.el5    BUILT: Fri Oct 24 07:37:33 CDT 2008
lvm2-cluster-2.02.40-7.el5    BUILT: Wed Nov 26 07:19:19 CST 2008
device-mapper-1.02.28-2.el5    BUILT: Fri Sep 19 02:50:32 CDT 2008

How reproducible:
Everytime

Comment 1 Corey Marthaler 2009-01-26 22:07:48 UTC
Same thing happens when you split out the LV at the base level.

vgsplit -n /dev/base0/base0 base0 ten

[root@hayes-03 ~]# lvs -a -o +devices
  Couldn't find device with uuid '6cKqpw-UTjG-SXJ4-o2sC-cG8q-9AA5-GMykGx'.
  LV       VG         Attr   LSize   Origin Snap%  Move Log Copy%  Convert Devices              
  LogVol00 VolGroup00 -wi-ao  64.56G                                       /dev/sda2(0)         
  LogVol01 VolGroup00 -wi-ao   9.81G                                       /dev/sda2(2066)      
  base1    base1      -wi-a- 800.00M                                       /dev/etherd/e1.1p5(0)
  base0    ten        -wi--- 800.00M                                       /dev/etherd/e1.1p3(0)
[root@hayes-03 ~]# pvscan
  Couldn't find device with uuid '6cKqpw-UTjG-SXJ4-o2sC-cG8q-9AA5-GMykGx'.
  PV /dev/etherd/e1.1p5   VG base1           lvm2 [1.77 TB / 1.77 TB free]
  PV /dev/etherd/e1.1p3   VG ten             lvm2 [1.77 TB / 1.77 TB free]
  PV /dev/etherd/e1.1p2   VG base0           lvm2 [1.77 TB / 1.77 TB free]
  PV unknown device       VG seven           lvm2 [796.00 MB / 796.00 MB free]
  PV /dev/base1/base1     VG seven           lvm2 [796.00 MB / 796.00 MB free]
  PV /dev/sda2            VG VolGroup00      lvm2 [74.38 GB / 0    free]
  PV /dev/etherd/e1.1p1                      lvm2 [1.77 TB]
  PV /dev/etherd/e1.1p4                      lvm2 [1.77 TB]

[root@hayes-03 ~]# vgchange -an
  0 logical volume(s) in volume group "base1" now active
  0 logical volume(s) in volume group "ten" now active
  0 logical volume(s) in volume group "base0" now active
  /dev/base1/base1: stat failed: No such file or directory
  Path /dev/base1/base1 no longer valid for device(253,3)
  /dev/mapper/base1-base1: stat failed: No such file or directory
  Path /dev/mapper/base1-base1 no longer valid for device(253,3)
  /dev/mapper/base1-base1: stat failed: No such file or directory
  Path /dev/mapper/base1-base1 no longer valid for device(253,3)
  Volume group "seven" not found
  /dev/mapper/base1-base1: stat failed: No such file or directory
  Path /dev/mapper/base1-base1 no longer valid for device(253,3)
  Can't deactivate volume group "VolGroup00" with 2 open logical volume(s)

Comment 2 Peter Rajnoha 2009-03-17 16:04:54 UTC
We do not fully support stacked devices yet. This one still needs more design work.

Comment 5 Milan Broz 2011-10-21 16:11:48 UTC
Stacked device support this way is not supported in RHEL5 and it perhaps need new RFE. Closing this, I do not expect this will be fixed in RHEL5.


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