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 837093 - nosync mirror|raid attribute removal during down and up convert
Summary: nosync mirror|raid attribute removal during down and up convert
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: lvm2
Version: 6.3
Hardware: x86_64
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: Jonathan Earl Brassow
QA Contact: Cluster QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-07-02 18:17 UTC by Corey Marthaler
Modified: 2013-02-21 08:11 UTC (History)
9 users (show)

Fixed In Version: lvm2-2.02.98-1.el6
Doc Type: Bug Fix
Doc Text:
When a RAID or mirror logical volume is created with the '--nosync' option, an attribute is attached to the logical volume to indicate this. Previously, a RAID1 logical volume that had this attribute that was converted to a linear logical volume and back would not clear this attribute - even though it would undergo a complete resync in the process. This has been corrected and the 'nosync' attribute is now properly cleared.
Clone Of:
Environment:
Last Closed: 2013-02-21 08:11:10 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2013:0501 0 normal SHIPPED_LIVE lvm2 bug fix and enhancement update 2013-02-20 21:30:45 UTC

Description Corey Marthaler 2012-07-02 18:17:16 UTC
Description of problem:
Mirror and Raid attributes behave differently when up and down converted.

## MIRROR ##

[root@hayes-01 bin]# lvs -a -o +devices
  LV                       Attr     LSize   Log               Copy%  Devices
  initial_sync             Mwi-a-m- 100.00m initial_sync_mlog 100.00 initial_sync_mimage_0(0),initial_sync_mimage_1(0)
  [initial_sync_mimage_0]  iwi-aom- 100.00m                          /dev/etherd/e1.1p9(0)
  [initial_sync_mimage_1]  iwi-aom- 100.00m                          /dev/etherd/e1.1p8(0)
  [initial_sync_mlog]      lwi-aom-   4.00m                          /dev/etherd/e1.1p1(0)

[root@hayes-01 bin]# lvconvert -m 0 /dev/mirror_sanity/initial_sync
  Logical volume initial_sync converted.
[root@hayes-01 bin]# lvs -a -o +devices
  LV           VG            Attr     LSize   Log Copy%  Devices
  initial_sync mirror_sanity -wi-a--- 100.00m            /dev/etherd/e1.1p9(0)

[root@hayes-01 bin]# lvconvert -m 1 /dev/mirror_sanity/initial_sync
  mirror_sanity/initial_sync: Converted: 16.0%
  mirror_sanity/initial_sync: Converted: 100.0%

# Note the "M" is now "m"
[root@hayes-01 bin]# lvs -a -o +devices
  LV                       Attr     LSize   Log               Copy%  Devices
  initial_sync             mwi-a-m- 100.00m initial_sync_mlog 100.00 initial_sync_mimage_0(0),initial_sync_mimage_1(0)
  [initial_sync_mimage_0]  iwi-aom- 100.00m                          /dev/etherd/e1.1p9(0)
  [initial_sync_mimage_1]  iwi-aom- 100.00m                          /dev/etherd/e1.1p8(0)
  [initial_sync_mlog]      lwi-aom-   4.00m                          /dev/etherd/e1.1p1(0)


## RAID ##

[root@hayes-01 bin]# lvs -a -o +devices
  LV                       Attr     LSize   Copy%  Devices
  initial_sync             Rwi-a-m- 100.00m 100.00 initial_sync_rimage_0(0),initial_sync_rimage_1(0)
  [initial_sync_rimage_0]  iwi-aor- 100.00m        /dev/etherd/e1.1p9(1)
  [initial_sync_rimage_1]  iwi-aor- 100.00m        /dev/etherd/e1.1p8(1)
  [initial_sync_rmeta_0]   ewi-aor-   4.00m        /dev/etherd/e1.1p9(0)
  [initial_sync_rmeta_1]   ewi-aor-   4.00m        /dev/etherd/e1.1p8(0)

[root@hayes-01 bin]# lvconvert --type raid1 -m 0 raid_sanity/initial_sync
[root@hayes-01 bin]# lvs -a -o +devices
  LV           VG          Attr     LSize   Copy%  Devices
  initial_sync raid_sanity -wi-a--- 100.00m        /dev/etherd/e1.1p9(1)

# Note the "R" is still "R"
[root@hayes-01 bin]# lvconvert --type raid1 -m 1 raid_sanity/initial_sync
[root@hayes-01 bin]# lvs -a -o +devices
  LV                       Attr     LSize   Copy%  Devices
  initial_sync             Rwi-a-m- 100.00m  48.00 initial_sync_rimage_0(0),initial_sync_rimage_1(0)
  [initial_sync_rimage_0]  Iwi-aor- 100.00m        /dev/etherd/e1.1p9(1)
  [initial_sync_rimage_1]  Iwi-aor- 100.00m        /dev/etherd/e1.1p8(1)
  [initial_sync_rmeta_0]   ewi-aor-   4.00m        /dev/etherd/e1.1p9(0)
  [initial_sync_rmeta_1]   ewi-aor-   4.00m        /dev/etherd/e1.1p8(0)



Version-Release number of selected component (if applicable):
2.6.32-278.el6.x86_64
lvm2-2.02.95-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012
lvm2-libs-2.02.95-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012
lvm2-cluster-2.02.95-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012
udev-147-2.41.el6    BUILT: Thu Mar  1 13:01:08 CST 2012
device-mapper-1.02.74-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012
device-mapper-libs-1.02.74-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012
device-mapper-event-1.02.74-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012
device-mapper-event-libs-1.02.74-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012
cmirror-2.02.95-10.el6    BUILT: Fri May 18 03:26:00 CDT 2012

Comment 1 RHEL Program Management 2012-07-10 06:01:31 UTC
This request was not resolved in time for the current release.
Red Hat invites you to ask your support representative to
propose this request, if still desired, for consideration in
the next release of Red Hat Enterprise Linux.

Comment 2 RHEL Program Management 2012-07-10 23:59:24 UTC
This request was erroneously removed from consideration in Red Hat Enterprise Linux 6.4, which is currently under development.  This request will be evaluated for inclusion in Red Hat Enterprise Linux 6.4.

Comment 3 Jonathan Earl Brassow 2012-09-14 21:29:24 UTC
UNIT TEST:

[root@hayes-01 lvm2]# lvcreate --type raid1 -m1 -L 500M -n lv vg --nosync
  WARNING: New raid1 won't be synchronised. Don't read what you didn't write!
  Logical volume "lv" created

[root@hayes-01 lvm2]# lvs vg
  LV   VG   Attr     LSize   Pool Origin Data%  Move Log Copy%  Convert
  lv   vg   Rwi-a-r- 500.00m                             100.00        

[root@hayes-01 lvm2]# lvconvert -m 0 vg/lv

[root@hayes-01 lvm2]# lvs vg
  LV   VG   Attr     LSize   Pool Origin Data%  Move Log Copy%  Convert
  lv   vg   -wi-a--- 500.00m                                           

[root@hayes-01 lvm2]# lvconvert --type raid1 -m 1 vg/lv

[root@hayes-01 lvm2]# lvs vg
  LV   VG   Attr     LSize   Pool Origin Data%  Move Log Copy%  Convert
  lv   vg   rwi-a-r- 500.00m                              24.80

Comment 4 Jonathan Earl Brassow 2012-09-14 21:29:54 UTC
commit 2a6712ddefb6720d115d11c276223b57abf5dd94
Author: Jonathan Brassow <jbrassow>
Date:   Fri Sep 14 16:26:53 2012 -0500

    RAID1:  Clear the LV_NOTSYNCED flag when a RAID1 LV is converted to linear
    
    Failing to clear the LV_NOTSYNCED flag when converting a RAID1 LV to
    linear can result in the flag being present after an upconvert - even
    if the sync is performed when upconverting.

Comment 6 Corey Marthaler 2013-01-22 01:05:54 UTC
Fix verified in the latest rpms.


2.6.32-354.el6.x86_64
lvm2-2.02.98-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013
lvm2-libs-2.02.98-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013
lvm2-cluster-2.02.98-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013
udev-147-2.43.el6    BUILT: Thu Oct 11 05:59:38 CDT 2012
device-mapper-1.02.77-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013
device-mapper-libs-1.02.77-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013
device-mapper-event-1.02.77-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013
device-mapper-event-libs-1.02.77-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013
cmirror-2.02.98-8.el6    BUILT: Wed Jan 16 07:57:25 CST 2013



SCENARIO (raid1) - [verify_no_initial_sync_attr]
Making nosync raid and verifying it has the 'no initial sync' attr
qalvm-01: lvcreate --type raid1 -m 1 -n initial_sync -L 100M --nosync raid_sanity
  WARNING: New raid1 won't be synchronised. Don't read what you didn't write!
Down and then up convert raid to cause the 'R' attr to be dropped
qalvm-01: lvconvert --type raid1 -m 0 raid_sanity/initial_sync
qalvm-01: lvconvert --type raid1 -m 1 raid_sanity/initial_sync

  initial_sync raid_sanity rwi-a-r-- 100.00m 100.00 initial_sync_rimage_0(0),initial_sync_rimage_1(0)

Comment 7 errata-xmlrpc 2013-02-21 08:11:10 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-2013-0501.html


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