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 747278 - installer does not check lvm name lengths
Summary: installer does not check lvm name lengths
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: anaconda
Version: 6.2
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: David Lehman
QA Contact: Release Test Team
URL:
Whiteboard: abrt_hash:c312445fffb41e8f4f32c0186d1...
: 747544 (view as bug list)
Depends On:
Blocks: 756082 840685
TreeView+ depends on / blocked
 
Reported: 2011-10-19 10:50 UTC by Michal Nowak
Modified: 2013-03-08 02:12 UTC (History)
15 users (show)

Fixed In Version: anaconda-13.21.191-1
Doc Type: Bug Fix
Doc Text:
Do not use hyphens in LVM volume group names or logical volume names. Keep each name under 64 characters in length, ensuring that the total length of the volume group name plus the logical volume name does not exceed 126 characters in length. Most people will not have problems with this limitation. Use short names and you will be fine.
Clone Of:
Environment:
Last Closed: 2013-02-21 09:58:27 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
File: anaconda-tb-Xt1gNJ (175.09 KB, text/plain)
2011-10-19 10:50 UTC, Michal Nowak
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2013:0373 0 normal SHIPPED_LIVE anaconda bug fix and enhancement update 2013-02-20 20:52:28 UTC

Description Michal Nowak 2011-10-19 10:50:44 UTC
abrt version: 2.0.5
executable:     /mnt/runtime/usr/bin/python
hashmarkername: anaconda
kernel:         2.6.32-209.el6.x86_64
product:        Red Hat Enterprise Linux
reason:         LVMError: lvcreate failed for vg_aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/lv_root: 06:11:27,670 ERROR   :   Failed to activate new LV.
time:           Wed Oct 19 06:32:44 2011
version:        6.2

anaconda-tb-Xt1gNJ: Text file, 179295 bytes

description:
:The following was filed automatically by anaconda:
:anaconda 13.21.145 exception report
:Traceback (most recent call first):
:  File "/usr/lib/anaconda/storage/devicelibs/lvm.py", line 379, in lvcreate
:    raise LVMError("lvcreate failed for %s/%s: %s" % (vg_name, lv_name, msg))
:  File "/usr/lib/anaconda/storage/devices.py", line 2517, in create
:    lvm.lvcreate(self.vg.name, self._name, self.size, progress=w)
:  File "/usr/lib/anaconda/storage/deviceaction.py", line 204, in execute
:    self.device.create(intf=intf)
:  File "/usr/lib/anaconda/storage/devicetree.py", line 713, in processActions
:    action.execute(intf=self.intf)
:  File "/usr/lib/anaconda/storage/__init__.py", line 344, in doIt
:    self.devicetree.processActions()
:  File "/usr/lib/anaconda/packages.py", line 110, in turnOnFilesystems
:    anaconda.id.storage.doIt()
:  File "/usr/lib/anaconda/dispatch.py", line 208, in moveStep
:    rc = stepFunc(self.anaconda)
:  File "/usr/lib/anaconda/dispatch.py", line 126, in gotoNext
:    self.moveStep()
:  File "/usr/lib/anaconda/gui.py", line 1478, in setScreen
:    self.anaconda.dispatch.gotoNext()
:  File "/usr/lib/anaconda/gui.py", line 1391, in nextClicked
:    self.setScreen ()
:LVMError: lvcreate failed for vg_aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/lv_root: 06:11:27,670 ERROR   :   Failed to activate new LV.
:
:</LOG>

Comment 1 Michal Nowak 2011-10-19 10:50:50 UTC
Created attachment 528970 [details]
File: anaconda-tb-Xt1gNJ

Comment 3 David Lehman 2011-10-19 13:56:20 UTC
06:11:27,669 ERROR   :   Name "vg_aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-lv_root" too long
06:11:27,670 ERROR   :   Failed to set device name for vg_aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-lv_root
06:11:27,670 ERROR   :   Failed to activate new LV.

Comment 4 Michal Nowak 2011-10-20 08:57:37 UTC
*** Bug 747544 has been marked as a duplicate of this bug. ***

Comment 5 David Cantrell 2011-10-24 18:27:22 UTC
I'm sure we're hitting a label length limit here.  What is the LVM label length limit we should be enforcing at install time?  Is there a good location we can reference for that limit?

(feel free to answer the questions and reassign the bug back to anaconda)

Comment 6 Alasdair Kergon 2011-10-24 18:39:31 UTC
Well the underlying restriction is that the vgname + lvname lengths together must not exceed 126 minus the total number of hyphens in them.

So 63 bytes is a reasonable limit to use for each, as long as you deduct one from it for each hyphen included in the name.

Comment 7 Alasdair Kergon 2011-10-24 18:46:51 UTC
Internal names used for snapshots etc. can take up a further 8 characters so maybe make the limit 59 characters minus number of hyphens.

Comment 8 Alasdair Kergon 2011-10-24 18:55:56 UTC
The hyphen thing is because the hyphen is used internally as a separator, so any hyphens in the name are escaped by doubling them, eating up an extra character.

Comment 9 David Cantrell 2011-10-24 19:25:14 UTC
Thanks, Alasdair.  I'm going to add a technote for this (not that anyone will ever read it) and we can fix it up in 6.3.

Comment 10 David Cantrell 2011-10-24 19:25:16 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Do not use hyphens in LVM volume group names or logical volume names.  Keep each name under 64 characters in length, ensuring that the total length of the volume group name plus the logical volume name does not exceed 126 characters in length.  Most people will not have problems with this limitation.  Use short names and you will be fine.

Comment 11 Alasdair Kergon 2011-10-24 19:34:22 UTC
Indeed. I've never come across a customer problem from using names that are too long, which is why LVM still only has minimal validation in this area.

Comment 20 RHEL Program Management 2012-07-16 22:49:22 UTC
This request was evaluated by Red Hat Product Management for
inclusion in a Red Hat Enterprise Linux release.  Product
Management has requested further review of this request by
Red Hat Engineering, for potential inclusion in a Red Hat
Enterprise Linux release for currently deployed products.
This request is not yet committed for inclusion in a release.

Comment 25 Alexander Todorov 2013-01-16 10:52:41 UTC
with snap #3:

In GUI:
* LV name is limited to 32 characters
* VG name is limited to 16 characters

When testing with ks.cfg from comment #22 VG name was truncated to 50 characters and installation completed.

Comment 26 errata-xmlrpc 2013-02-21 09:58:27 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-0373.html


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