Detaching the VM

Once the VM is "Ready to detach" and the preparing to detach task completes successfully, you can detach the VM. You must assign a scheduled downtime slot for detaching.

Detaching is a sequence in which the VM will shut down, perform necessary last synchronization including adjusting instance size, attach the native disks to the instance, and start the instance.

After detaching the VM, perform any required validation that the VM is functioning correctly, and then either cleanup or rollback (if you do not want to detach the VM from Velostrata). See Starting the Detach Cleanup

On-prem-to-Cloud: To detach in vSphere:
  1. On the vSphere Web Client, select the desired Virtual Machine.
  2. Right-click on the required VM and select Velostrata Operations > Migration Operations > Detach.
  3. Select a new instance type (optional) and click OK. 

You can monitor the detach progress from vCenter:

After the  detach process is completed, the VM state will be listed as Detached.

On-prem-to-Cloud: To detach the VM using PowerShell:
  1. In Powershell, connect to the Velostrata Manager by running Connect-VelostrataManager.
  1. When prompted enter details for the Server, Username (apiuser) and Password (the subscription ID).
  2. To detach the VM, run get-vm myserver | Start-VelosDetach -InstanceType string.

Note: To find the InstanceType you can use the Get-VelosCeInstanceType command.

  1. To check the state of the task, run Get-Velostask [ID] and optionally Get-Velostask [ID] |fl *
  1. Monitor the created vSphere Cloud Instance Information and task. The VM State is Stopped and the Storage Migration is Detaching.

Once the task completes successfully the VM State is Running and the Storage Migration is Detached.


  1. Connect to the VM and perform the necessary validations. For example, in Azure you can use "Boot Diagnostics" to see the VM has been booted. 
Cloud-to-Cloud: To detach the VM using PowerShell:

This cmdlet starts the detach sequence for the specified workload in the target cloud.  The workload must be in the "Ready to Detach" state in order to to perform this operation.  Once finished, the workload boots and runs natively in the target cloud.  You must assign a scheduled downtime slot for detaching.

  • To detach the VM, run Start-VelosDetach -ID i-123abcd -InstanceType string.
Note for AWS Marketplace Users:

If the VM was created in an AWS marketplace Cloud Extension, when the instance is detached from Velostrata, it is detached from the marketplace CE, a new instance is created with a bring your own license, and the volumes are attached to this new instance. Although the instance ID has changed, this has no impact on the operation of the instance as it has the same ENI ID and Private IP. The routing rules are also still valid. If the detach is canceled, the instance may or may not have the original instance ID. Nevertheless, the instance will have the same IP and tagging.