Bug 1121216

Summary: '--alloc' option needs to be allowed with 'lvconvert --repair'
Product: Red Hat Enterprise Linux 6 Reporter: Corey Marthaler <cmarthal>
Component: lvm2Assignee: Zdenek Kabelac <zkabelac>
lvm2 sub component: Changing Logical Volumes (RHEL6) QA Contact: Cluster QE <mspqa-list>
Status: CLOSED ERRATA Docs Contact:
Severity: medium    
Priority: unspecified CC: agk, heinzm, jbrassow, msnitzer, prajnoha, prockai, tlavigne, zkabelac
Version: 6.6   
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: lvm2-2.02.108-1.el6 Doc Type: Bug Fix
Doc Text:
lvconvert --repair now accepts a few additional arguments including --alloc and --force.
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-10-14 08:25:29 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Corey Marthaler 2014-07-18 16:23:46 UTC
Description of problem:
This issue is for the "failure" found in bug 877221#c15. This should be fixed in rhel6.6.


[root@host-002 ~]# lvconvert --alloc anywhere  --repair -y vg1/lvol0 /dev/sda1
  Option --alloc cannot be used with --repair.
  Run `lvconvert --help' for more information.


Version-Release number of selected component (if applicable):
2.6.32-485.el6.x86_64
lvm2-2.02.107-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014
lvm2-libs-2.02.107-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014
lvm2-cluster-2.02.107-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014
udev-147-2.55.el6    BUILT: Wed Jun 18 06:30:21 CDT 2014
device-mapper-1.02.86-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014
device-mapper-libs-1.02.86-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014
device-mapper-event-1.02.86-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014
device-mapper-event-libs-1.02.86-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014
device-mapper-persistent-data-0.3.2-1.el6    BUILT: Fri Apr  4 08:43:06 CDT 2014
cmirror-2.02.107-2.el6    BUILT: Fri Jul 11 08:47:33 CDT 2014

Comment 1 Zdenek Kabelac 2014-08-19 13:14:35 UTC
Fixed via upstream commit:

https://www.redhat.com/archives/lvm-devel/2014-July/msg00099.html

Comment 2 Peter Rajnoha 2014-08-19 14:26:44 UTC
OK, that was in lvm2-2.02.109-2.el6. Adding to errata then...

Comment 4 Corey Marthaler 2014-09-03 22:14:42 UTC
Fix verified in the latest rpms.

2.6.32-495.el6.x86_64
lvm2-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
lvm2-libs-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
lvm2-cluster-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
udev-147-2.57.el6    BUILT: Thu Jul 24 08:48:47 CDT 2014
device-mapper-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-libs-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-event-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-event-libs-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-persistent-data-0.3.2-1.el6    BUILT: Fri Apr  4 08:43:06 CDT 2014
cmirror-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014

[root@host-050 ~]# lvconvert --alloc anywhere  --repair -y vg1/lvol0 /dev/sda1
  /dev/sdc1: open failed: No such device or address
  Couldn't find device with uuid cqZiXG-Uw6y-Mp1o-tZG5-VgZG-OXP0-VY2Yfd.
  Faulty devices in vg1/lvol0 successfully replaced.

[root@host-050 ~]# lvs --all --segments -o +devices
  Couldn't find device with uuid cqZiXG-Uw6y-Mp1o-tZG5-VgZG-OXP0-VY2Yfd.
  LV               VG  Attr       #Str Type   SSize    Devices
  lvol0            vg1 rwi-a-r---    2 raid1  1000.00m lvol0_rimage_0(0),lvol0_rimage_1(0)
  [lvol0_rimage_0] vg1 iwi-aor---    1 linear 1000.00m /dev/sda1(2)
  [lvol0_rimage_1] vg1 iwi-aor---    1 linear  800.00m /dev/sdb1(1)
  [lvol0_rimage_1] vg1 iwi-aor---    1 linear  200.00m /dev/sdd1(0)
  [lvol0_rmeta_0]  vg1 ewi-aor---    1 linear    4.00m /dev/sda1(1)
  [lvol0_rmeta_1]  vg1 ewi-aor---    1 linear    4.00m /dev/sdb1(0)

Comment 5 errata-xmlrpc 2014-10-14 08:25:29 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.

http://rhn.redhat.com/errata/RHBA-2014-1387.html