Red Hat Bugzilla – Bug 479006
device-mapper should check for maximal volume name length
Last modified: 2013-02-28 23:07:51 EST
dmsetup ignores part of provided volume name length quietly
# dmsetup create 012345678901234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456andthisisignored --table "0 1 error"
# dmsetup table
0123456789012345678900123456789001234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456: 0 1 error
The same check is needed for rename (there is even bug in kernel which allows longer string, then you must address device by using major:minor)
[I sent kernel patch just few minutes ago, but userpsce need to be fixed too]
# dmsetup rename 0123456789012345678900123456789001234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456 012345678901234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456andthisisignored
Unable to rename device node from '0123456789012345678900123456789001234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456' to '012345678901234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456789001234567890012345678900123456andthisisignored'
(the above command should fail in commandline paramaters validation)
# dmsetup table
device-mapper: table ioctl failed: No such device or address
(situation above this is just demonstration of kernel bug, there is device with longer name in kernel than ioctl allows to address)
# dmsetup table -j 253 -m 0
0 1 error
- all device-mapper related commands should check for DM_NAME_LEN (it includes trailing zero.
Check for name length has been added as well as check for incorrect names containing '/' character in "dmsetup create" and "dmsetup rename" (the device does not exist in filesystem yet, so entering the path is not allowed).
The fix has been uploaded to upstream CVS (DM version 1.02.30).
This bug appears to have been reported against 'rawhide' during the Fedora 11 development cycle.
Changing version to '11'.
More information and reason for this action is here:
lvm2-2.02.48-1.fc11 has been submitted as an update for Fedora 11.
lvm2-2.02.48-1.fc11 has been pushed to the Fedora 11 testing repository. If problems still persist, please make note of it in this bug report.
If you want to test the update, you can install it with
su -c 'yum --enablerepo=updates-testing update lvm2'. You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-7468
lvm2-2.02.48-1.fc11 has been pushed to the Fedora 11 stable repository. If problems still persist, please make note of it in this bug report.