holland-coredev team mailing list archive
-
holland-coredev team
-
Mailing list archive
-
Message #00302
[Bug 1117683] Re: mysql-lvm does not handle invalid snapshot names gracefully
** Changed in: holland-backup
Milestone: None => 1.0.12
--
You received this bug notification because you are a member of Holland
Build, which is subscribed to holland-backup.
https://bugs.launchpad.net/bugs/1117683
Title:
mysql-lvm does not handle invalid snapshot names gracefully
Status in Holland Backup Framework:
New
Bug description:
With a misconfiguration of the sort:
snapshot-name = /tmp/foo
Where snapshot-name is set rather than snapshot-mountpoint, lvcreate
will still succeed but lvm2 will set the snapshot name to $(basename
${snapshot_name}). E.g. ${volume_group}/foo in this case. However,
mysql-lvm attempts to verify the snapshot was created by looking up
${volume_group}/${snapshot_name} = ${volume_group}/tmp/foo which will
never exist as '/' is never allowed in a snapshot name.
Right now, mysql-lvm is failing to catch the exception the volume API
is raising when the snapshot cannot be found and this leads to a messy
"uncaught exception" error. At the very least this should be caught
and an appropriate error output and even better, the bad snapshot name
should error out far before we get to this point.
LVM2 documents the valid snapshot names as:
VALID NAMES
The following characters are valid for VG and LV names: a-z A-Z 0-9 + _ . -
VG and LV names cannot begin with a hyphen. There are also various reserved names that are used internally by lvm that can not be used as LV or VG names. A VG cannot be called anything that exists in /dev/
at the time of creation, nor can it be called ’.’ or ’..’. A LV cannot be called ’.’ ’..’ ’snapshot’ or ’pvmove’. The LV name may also not contain the strings ’_mlog’ or ’_mimage’
To manage notifications about this bug go to:
https://bugs.launchpad.net/holland-backup/+bug/1117683/+subscriptions
References