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 612248 - splitting off the last mirror image causes error messages
Summary: splitting off the last mirror image causes error messages
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: lvm2
Version: 6.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Jonathan Earl Brassow
QA Contact: Corey Marthaler
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-07-07 16:35 UTC by Corey Marthaler
Modified: 2010-11-10 21:08 UTC (History)
8 users (show)

Fixed In Version: lvm2-2.02.72-2.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-11-10 21:08:20 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Corey Marthaler 2010-07-07 16:35:24 UTC
Description of problem:
[root@grant-02 ~]# lvs -a -o +devices
  LV                VG         Attr   LSize   Log         Copy%  Convert Devices
  mirror            grant      mwi-a- 100.00m mirror_mlog 100.00         mirror_mimage_0(0),mirror_mimage_1(0),mirror_mimage_2(0)
  [mirror_mimage_0] grant      iwi-ao 100.00m                            /dev/sdb1(0)
  [mirror_mimage_1] grant      iwi-ao 100.00m                            /dev/sdb2(0)
  [mirror_mimage_2] grant      iwi-ao 100.00m                            /dev/sdc1(0)
  [mirror_mlog]     grant      lwi-ao   4.00m                            /dev/sdc2(0)

[root@grant-02 ~]# lvconvert --splitmirrors 1 --name newA grant/mirror /dev/sdc1
  Logical volume mirror converted.

[root@grant-02 ~]# lvs -a -o +devices
  LV                VG         Attr   LSize   Log         Copy%  Convert Devices
  mirror            grant      mwi-a- 100.00m mirror_mlog 100.00         mirror_mimage_0(0),mirror_mimage_1(0)
  [mirror_mimage_0] grant      iwi-ao 100.00m                            /dev/sdb1(0)
  [mirror_mimage_1] grant      iwi-ao 100.00m                            /dev/sdb2(0)
  [mirror_mlog]     grant      lwi-ao   4.00m                            /dev/sdc2(0)
  newA              grant      -wi-a- 100.00m                            /dev/sdc1(0)

[root@grant-02 ~]# lvconvert --splitmirrors 1 --name newB grant/mirror /dev/sdb2
  Internal error: _memlock_count has dropped below 0.
  Internal error: _memlock_count has dropped below 0.
  Logical volume mirror converted.

[root@grant-02 ~]# lvs -a -o +devices
  LV      VG         Attr   LSize   Log Copy%  Convert Devices
  mirror  grant      -wi-a- 100.00m                    /dev/sdb1(0)
  newA    grant      -wi-a- 100.00m                    /dev/sdc1(0)
  newB    grant      -wi-a- 100.00m                    /dev/sdb2(0)


Version-Release number of selected component (if applicable):
lvm2-2.02.69-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010
lvm2-libs-2.02.69-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010
lvm2-cluster-2.02.69-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010
device-mapper-1.02.51-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010
device-mapper-libs-1.02.51-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010
device-mapper-event-1.02.51-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010
device-mapper-event-libs-1.02.51-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010
cmirror-2.02.69-2.el6    BUILT: Fri Jul  2 07:26:01 CDT 2010

How reproducible:
everytime

Comment 1 Peter Rajnoha 2010-07-09 12:01:48 UTC
(In reply to comment #0)
> [root@grant-02 ~]# lvconvert --splitmirrors 1 --name newB grant/mirror
> /dev/sdb2
>   Internal error: _memlock_count has dropped below 0.
>   Internal error: _memlock_count has dropped below 0.
>   Logical volume mirror converted.

Well, in this case, while splitting off the mirror in _split_mirror_image fn, a suspend is called for the original device tree as a whole. This calls just one memlock_inc internally for the tree.

When trying to resume particular devices (not the whole tree) just after that, memlock_dec gets called as many times as the resume is called, resulting in that _memlock_count to drop below 0...

Comment 3 Jonathan Earl Brassow 2010-07-12 14:31:02 UTC
Preliminary patch sent to lvm-devel

Comment 4 Jonathan Earl Brassow 2010-07-13 21:55:08 UTC
pending version 2.02.71

Comment 5 RHEL Program Management 2010-07-15 13:58:31 UTC
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release. It has
been denied for the current Red Hat Enterprise Linux release.

** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **

Comment 8 Corey Marthaler 2010-07-28 23:07:20 UTC
Fix verified in the latest build.

2.6.32-52.el6.x86_64

lvm2-2.02.72-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010
lvm2-libs-2.02.72-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010
lvm2-cluster-2.02.72-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010
udev-147-2.21.el6    BUILT: Mon Jul 12 04:55:00 CDT 2010
device-mapper-1.02.53-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010
device-mapper-libs-1.02.53-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010
device-mapper-event-1.02.53-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010
device-mapper-event-libs-1.02.53-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010
cmirror-2.02.72-3.el6    BUILT: Wed Jul 28 15:39:43 CDT 2010

Comment 9 releng-rhel@redhat.com 2010-11-10 21:08:20 UTC
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.


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