Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0

Reference

https://cwiki.apache.org/confluence/display/CLOUDSTACK/Volume+snapshot+enhancements+for+VMware

Feature Specification

Current volume snapshot operation flow is described as below

  • CreateSnapshot API command is issued from end-user/third-party API call
  • Snapshot Manager starts and orchestrates the operation execution flow
  • Snapshot management commands (ManageSnapshotCommand/BackupSnapshotCommand) are sent to VmwareResource resource instance
  • VmwareGuru filters snapshot commands, it help locate an available secondary storage VM instance and performs command redirection to offload snapshot operation task to a chosen secondary storage VM. Snapshot workload load-rebalancing is taken at this step.
  • VmwareStorageManagerImpl (this is running inside a secondary storage VM) finally carries on the operation with vCenter/ESX host
    • It first take a VM snapshot on the VM that the volume is attached to
    • After VM snapshot has been taken, it will analyze the composition of the VM snapshot, retrieve the disk chain information of the subject volume and creates a worker VM based on the disk chain.
    • By using vCenter API, it exports the disk content (full-copy) into the mounted NFS share in the secondary storage VM. Disk content includes .VMX OVF and .VMDK files
    • It finally package disk content (.VMX OVF file and .VMDK file) into OVA file format
  • Complete the snapshot operation

...

Internal storage format for snapshot, template and volume on Secondary storage will no longer be OVA. In stead of packing .VMX OVF and .VMDK into .OVA file, CloudStack only stores OVA meta information into a property file. The property file will be named with postfix .ova.meta. Content of the property file includes meta information of .VMX and .VMDK files, stored there to help generate OVA for exporting or importing into vCenter. Following gives some example content of the property file

version=1 (meta file version)

vmxovf=xxx.vmxovf

numDisks=1

disk1.name=xxxx.vmdk

...

ExtractTemplateCmd

Snapshot Commands

CreateSnapshotCmd

After the snapshot is create, in the snapshot directory on SEcondary Storage host, we will see the ovf and the vmdk files.
in dir: ~/Secondary/snapshots/2/13/
For example:
1 root root 68608 Apr 5 16:36 aa44054a-d099-4b9d-8fbf-211217381da0-disk0.vmdk
1 root root 3835 Apr 5 16:36 aa44054a-d099-4b9d-8fbf-211217381da0.ovf

In the previous scheme, we will see one ova file after the create snapshot command completes:
in dir ~Secondary/snapshots/2/7/,
ls:
1 root root 81920 Mar 27 15:18 db92a8e4-079f-4055-84f5-08d33f6f9fef.ova

DeleteSnapshotCmd

It will delete the snapshots related ovf, vmdk files for the new scheme. In the old scheme, it delets the ova file.

Volume Commands

CreateVolumeCmd

...