> -----Original Message----- > From: Donal Lafferty [mailto:donal.laffe...@citrix.com] > Sent: Wednesday, July 03, 2013 1:44 PM > To: dev@cloudstack.apache.org > Subject: Problems with using the TemplateObjectTO's checksum > > I'm trying to improve the performance of CopyCommand when copying a > TemplateObjectTO to a TemplateObjectTO. On Hyper-V this happens when > a template is downloaded from S3 to the hypervisor's primary data store. > > I notice that the checksum on a TemplateObjectTO cannot be used to verify > that an uncompressed image already exists on the destination. E.g. for a > System VM template, the checksum corresponds to the .bz2 file, and not > the .vhd Do you update template.sql with the uncompressed template url, and checksum?
For example, the following entry should be updated properly for both "checksum" field and "url" filed: INSERT INTO `cloud`.`vm_template` (id, uuid, unique_name, name, public, created, type, hvm, bits, account_id, url, checksum, enable_password, display_text, format, guest_os_id, featured, cross_zones, hypervisor_type) VALUES (9, UUID(), 'routing-9', 'SystemVM Template (HyperV)', 0, now(), 'SYSTEM', 0, 32, 1, 'http://download.cloud.com/templates/acton/acton-systemvm-02062012.vhd.bz2', 'f613f38c96bf039f2e5cbf92fa8ad4f8', 0, 'SystemVM Template (HyperV)', 'VHD', 15, 0, 1, 'Hyperv' ); > > Should I store only the compressed image, and take a performance hit during > uncompression? Or can I update the checksum for the TemplateObjectTO? > > Any suggestions welcome, > > DL