You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@vcl.apache.org by "Andy Kurth (JIRA)" <ji...@apache.org> on 2015/10/22 15:41:27 UTC

[jira] [Commented] (VCL-913) VCL KVM Libvirt provisioning module does not check length of the image's name when create an new image

    [ https://issues.apache.org/jira/browse/VCL-913?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14969171#comment-14969171 ] 

Andy Kurth commented on VCL-913:
--------------------------------

A similar issue was encountered with VMware VM's controlled by vCenter and the vSphere.sdk module.  The _\_clean\_vm\_name()_ subroutine in VMware.pm was created to shorten names.  I would suggest this subroutine be moved from VMware.pm to Provisioning.pm and renamed.

The VMware.pm module actually had a limit on the length of .vmdk files it could create (_although this is no longer the case_).  VMware.pm does not change the imagerevision.imagename value in the database when it detects it needs to use a shortened image name.  This is important because an image may be been captured on a hypervisor which could accommodate the longer name, and then the image is reloaded on a hypervisor which cannot.  If the name in the database is updated, it will break the original hypervisor from being able to load the image because it won't be able to find an image with the shortened name.  It has no way to determine what the longer name should be.

The libvirt.pm module should probably act in a similar way.  The original long name should always be stored in the database and not altered.  When libvirt.pm dectects it needs to use a shorter name, it should do so internally.  It sounds like the issue only pertains to the KVM instance name, which is mostly cosmetic, so this should be relatively easy to fix.

> VCL KVM Libvirt provisioning module does not check length of the image's name when create an new image
> ------------------------------------------------------------------------------------------------------
>
>                 Key: VCL-913
>                 URL: https://issues.apache.org/jira/browse/VCL-913
>             Project: VCL
>          Issue Type: Bug
>          Components: vcld (backend)
>    Affects Versions: 2.4.2
>            Reporter: Xianqing Yu
>
> When VCL use KVM and libvirt provisioning module to create an new image, it does not check the length of the image name. However, libvirt restrict the length of the name for a VM to be less than 50 characters. When I create an new image, VCL can create a very long image name, and final VM's name can be longer than 50 characters and libvirt will reject to boot the VM.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)