VMware nova driver – datastore image cache update improvements

Registered by Kiran Kumar Vaddi

VMware nova driver – datastore image cache update improvements
In the existing design, when an instance creation is done, the following occur
1. The existence of the image is checked in the cache (directory named _base_dir) on the cluster’s datastore
2. If the image is not available in the cache, then the image is downloaded from glance into nova (proxy VM) when the compute service runs, and then from the compute service to the datastore by vCenter
3. Instance is spawned using the cached image

Step 2 is a CPU intensive and time and bandwidth consuming task. The existing optimization being done throttle the number of images transferred and removed unnecessary queues. This is applicable for the first time the image is transferred to a datastore cache.
In case the same image is deployed into another cluster that exists on the same vCenter the process is repeated. This would mean that the same image is getting transferred multiple times between glance and nova for each cluster present in vCenter.
Proposal: If an image is available in the cache of one cluster, then copy of image from glance to nova (proxy VM) can be completely avoided by using vCenter APIs to copy the cached image from one datastore to another datastore. By using vCenter the progress of the task can be tracked as well. This approach works for clusters within the same vCenter.
With this approach the modified steps would be
1. The existence of the image is checked in the cache (_base directory) on ALL the cluster’s datastores using vCenter APIs
2. If the image is not available in ANY CLUSTERS the cache, then the image is downloaded from glance into nova (proxy VM) when the compute service runs, and then from the compute service to the datastore by vCenter
3. If the image is available in the cache of any cluster, then the image is copied to the other clusters cache using the vCenter API. This is very much efficient than the two hop transfer.
4. Instance is spawned using the cached image

Given that in a private cloud there will be different set of standard images, and the number of clusters in vCenter can be between 12 to 64, enhancing the model used to update the image cache in the datastore will significantly improve user experience, reduce instance creation times, reduce CPU load on the compute proxy and reduce traffic on the network

Blueprint information

Status:
Not started
Approver:
None
Priority:
Undefined
Drafter:
Kiran Kumar Vaddi
Direction:
Needs approval
Assignee:
None
Definition:
New
Series goal:
None
Implementation:
Unknown
Milestone target:
None

Related branches

Sprints

Whiteboard

Design specification in nova-specs
https://review.openstack.org/84662

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.