RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1104381 - RAID cache: Removing cache logical volume prints stray error message
Summary: RAID cache: Removing cache logical volume prints stray error message
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: lvm2
Version: 6.7
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Zdenek Kabelac
QA Contact: cluster-qe@redhat.com
URL:
Whiteboard:
Depends On:
Blocks: 1119326 1160903
TreeView+ depends on / blocked
 
Reported: 2014-06-03 21:18 UTC by Jonathan Earl Brassow
Modified: 2015-07-22 07:37 UTC (History)
9 users (show)

Fixed In Version: lvm2-2.02.117-1.el6
Doc Type: Bug Fix
Doc Text:
Wrong order of removed device when lvremoving cached volume resulted into printing an error message 'device not found'. Order has been fixed and this error is no longer printed.
Clone Of:
: 1160903 (view as bug list)
Environment:
Last Closed: 2015-07-22 07:37:21 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Possible patch to fix the problem (1017 bytes, patch)
2014-06-03 21:19 UTC, Jonathan Earl Brassow
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:1411 0 normal SHIPPED_LIVE lvm2 bug fix and enhancement update 2015-07-20 18:06:52 UTC

Description Jonathan Earl Brassow 2014-06-03 21:18:08 UTC
Stray error message when removing cache LVs:

[root@bp-01 lvm2]# lvremove -ff vg
  Logical volume "lv" successfully removed
  Logical volume "lv_cachepool" successfully removed
[root@bp-01 lvm2]# lvcreate --type raid1 -L 10G -n lv vg
  Logical volume "lv" created
[root@bp-01 lvm2]# lvcreate --type cache -L 1G -n lv_cachepool vg/lv
  Logical volume "lvol0" created
  Logical volume "lv" created
[root@bp-01 lvm2]# devices vg
  LV                   Attr       Cpy%Sync Devices                      
  lv                   Cwi-a-C---          lv_corig(0)                  
  lv_cachepool         Cwi---C---          lv_cachepool_cdata(0)        
  [lv_cachepool_cdata] Cwi---C---          /dev/sdb1(2563)              
  [lv_cachepool_cmeta] ewi---C---          /dev/sdb1(2562)              
  [lv_corig]           rwi---r---          lv_rimage_0(0),lv_rimage_1(0)
  [lv_rimage_0]        Iwi-aor-r-          /dev/sdb1(1)                 
  [lv_rimage_1]        Iwi-aor-r-          /dev/sdc1(1)                 
  [lv_rmeta_0]         ewi-aor-r-          /dev/sdb1(0)                 
  [lv_rmeta_1]         ewi-aor-r-          /dev/sdc1(0)                 
  [lvol0_pmspare]      ewi-------          /dev/sdb1(2561)              
[root@bp-01 lvm2]# lvremove -ff vg
  _get_device_info: LVM-BZoTdH7D3PTVbFFWTvbrqYOiIfvgTMg74k3bVmYzhIEB8N1ncVbVmIu1AwAoPWbw: device not found
  Logical volume "lv" successfully removed
  Logical volume "lv_cachepool" successfully removed


I've bisected the code and found the problem to come from commit 8a60cbcf45c553dfc168552cf9af3059359ec95d.  Specifically, it seems the portion that was removed that relates to cache LVs is the problem.  I'll post my patch that reverses that portion (and fixes this bug), for someone with better knowledge to look it over.

Comment 1 Jonathan Earl Brassow 2014-06-03 21:19:33 UTC
Created attachment 901912 [details]
Possible patch to fix the problem

Comment 2 Jonathan Earl Brassow 2014-08-27 12:43:00 UTC
not a blocker candidate due to tech preview status

Comment 3 Zdenek Kabelac 2014-09-25 09:02:51 UTC
This case should be supported with upstream (at least I'm not seeing any fault on my git tree) - yet the fixes my be result of recent fixes - so not sure if all hits 6.6 build - anyway - please retests.

It's already fixed for 6.7.

Comment 4 Jonathan Earl Brassow 2014-10-01 19:39:34 UTC
seems to be fixed upstream - having this in POST is fine, but it would be nice to know what commit fixed the issue or at least if it was fixed in the .111 release of LVM.

Comment 6 Peter Rajnoha 2014-11-13 09:06:09 UTC
(In reply to Jonathan Earl Brassow from comment #4)
> seems to be fixed upstream - having this in POST is fine, but it would be
> nice to know what commit fixed the issue or at least if it was fixed in the
> .111 release of LVM.

...still reproducible in v111 (which is in RHEL 6.6), so this is fixed in v112, so this fix will appear in 6.7.

Comment 8 Nenad Peric 2015-04-23 09:56:42 UTC
Did not hit an issue with the stray message. Used the reproducer mentioned in the opening comment, added a thin pool into the mix as well:

[root@tardis-02 ~]# lvs -a
  LV                   VG          Attr       LSize   Pool           Origin     Data%  Meta%  Move Log Cpy%Sync Convert
  lv                   vg          Cwi-a-C---  10.00g [lv_cachepool] [lv_corig] 0.03   1.90            0.00            
  [lv_cachepool]       vg          Cwi---C---   1.00g                           0.03   1.90            0.00            
  [lv_cachepool_cdata] vg          Cwi-ao----   1.00g                                                                  
  [lv_cachepool_cmeta] vg          ewi-ao----   8.00m                                                                  
  [lv_corig]           vg          rwi-aoC---  10.00g                                                  13.28           
  [lv_corig_rimage_0]  vg          Iwi-aor---  10.00g                                                                  
  [lv_corig_rimage_1]  vg          Iwi-aor---  10.00g                                                                  
  [lv_corig_rmeta_0]   vg          ewi-aor---   4.00m                                                                  
  [lv_corig_rmeta_1]   vg          ewi-aor---   4.00m                                                                  
  [lvol0_pmspare]      vg          ewi-------   8.00m                                                                  
  pool                 vg          twi-a-tz--  10.00g                           0.00   1.17                            
  [pool_tdata]         vg          Twi-ao----  10.00g                                                                  
  [pool_tmeta]         vg          ewi-ao----   4.00m                                                                  
  lv_home              vg_tardis02 -wi-ao---- 224.88g                                                                  
  lv_root              vg_tardis02 -wi-ao----  50.00g                                                                  
  lv_swap              vg_tardis02 -wi-ao----   4.00g                                                                  


[root@tardis-02 ~]# lvremove -ff vg
  Logical volume "lv_cachepool" successfully removed
  Logical volume "lv" successfully removed
  Logical volume "pool" successfully removed


Marking as verified with lvm2-2.02.118-2.el6.x86_64

Comment 9 errata-xmlrpc 2015-07-22 07:37:21 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.

https://rhn.redhat.com/errata/RHBA-2015-1411.html


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