Storage vMotion
Storage vMotion allows the hot migration of VM virtual disks between two different storage spaces. All files forming the VM migrate from one datastore to another in the same storage array or in another storage array without service interruption. The storage arrays can be from different manufacturers.
When to Use Storage vMotion
Storage vMotion is used for preventive maintenance operations for storage arrays. It can also be very useful when purchasing a new storage array because it does not require service interruption. Migration is performed very easily, in a fully transparent manner. This relieves administrators from this task, often a cumbersome and sensitive one in a traditional physical environment. Storage vMotion allows the administrator to switch storage array manufacturers and to migrate VMs without the need for a complex compatibility matrix.
How Storage vMotion Works
A number of improvements were made to Storage vMotion with vSphere 5. Several technologies have been used in the past. In vSphere 4.1, Dirty Block Tracking is used to copy disk blocks between source and destination: full copy, followed by the sending of modified blocks only to the target. (Dirty Block Tracking is a form of Changed Block Tracking [CBT] mode.) Issues with this technique were the duration of the switch to the target VM and the malfunction risk in cases of significant I/O load in the source VM. In vSphere 5, as shown in Figure 3.16, Storage vMotion makes a full copy of the VM and then uses a mirror driver to split write-modified blocks between the source and destination VMs.
Figure 3.16. Storage vMotion using a mirror driver.
This I/O mirroring is preferable to a succession of disk copies because it has the advantage of guaranteeing migration success even if the destination VM is slow. Migration will be shorter and more predictable.
The following occurs when using Storage vMotion:
- The VM’s working folder is copied to the destination datastore.
- An image of the VM, called a shadow VM, starts on the destination datastore by using the copied files. The shadow VM is paused.
- Storage vMotion activates a driver (called a mirror driver) to write a mirror of the blocks already copied to the destination.
- The copy of the VM’s disk files to the destination datastore is completed while the I/O is being mirrored.
- Storage vMotion pauses the source VM and transfers the source VM being executed to the shadow VM.
- The old folder and the VM’s disk files are deleted from the source datacenter.
Storage vMotion, available in the Enterprise version, works with VMs that have snapshots and also supports the migration of linked clones.