Deploy a new virtual machine based on a snapshot of a powered-on VM

A useful PowerCLI code snippet if you want to deploy a new virtual machine (VM) based on a snapshot of a powered-on VM:

New-VM -Name <new_vm_name> -VM <name_of_VM_with_snapshot> -Datastore <LUN_to_deploy_new_VM> -VMHost <Host_where_to_deploy_new_VM> -clone -ReferenceSnapshot <display_name_of_the_open_snapshot>

 

 

4 Comments

  1. Prashant

    How will this impact the networking of the VM’s?

  2. David Klee

    What version of PowerCLI are you using for this command?

  3. Private

    Does’nt work for me.
    Got an error that the ‘clone’ command is not available.

  4. Raj

    Hi Andrea,

    Thank you and this is much informative.

    Regards.
    Raj Navalgund

Leave a Comment

Your email address will not be published. Required fields are marked *