Package com.vmware.vm

Class VMRelocate


  • @Sample(name="vm-relocate",
            description="Used to relocate a linked clone using disk move type")
    public class VMRelocate
    extends ConnectedVimServiceBase
     VMRelocate
    
     Used to relocate a linked clone using disk move type
    
     Parameters:
     url            [required] : url of the web service
     username       [required] : username for the authentication
     password       [required] : password for the authentication
     vmname         [required] : name of the virtual machine
     diskmovetype   [required] : Either of
                                   [moveChildMostDiskBacking | moveAllDiskBackingsAndAllowSharing]
     datastorename  [required] : Name of the datastore
    
     Command Line:
     run.bat com.vmware.vm.VMRelocate --url [URLString] --username [User] --password [Password]
     --vmname [VMName] --diskmovetype [DiskMoveType] --datastorename [Datastore]
     
    • Constructor Detail

      • VMRelocate

        public VMRelocate()
    • Method Detail

      • setVmname

        @Option(name="vmname",
                description="name of the virtual machine")
        public void setVmname​(java.lang.String vmname)
      • setDiskMoveType

        @Option(name="diskmovetype",
                description="Either of\n[moveChildMostDiskBacking | moveAllDiskBackingsAndAllowSharing]")
        public void setDiskMoveType​(java.lang.String type)
      • setDatastoreName

        @Option(name="datastorename",
                description="Name of the datastore")
        public void setDatastoreName​(java.lang.String name)
      • run

        @Action
        public void run()
                 throws com.vmware.vim25.RuntimeFaultFaultMsg,
                        com.vmware.vim25.InsufficientResourcesFaultFaultMsg,
                        com.vmware.vim25.VmConfigFaultFaultMsg,
                        com.vmware.vim25.InvalidDatastoreFaultMsg,
                        com.vmware.vim25.InvalidPropertyFaultMsg,
                        com.vmware.vim25.FileFaultFaultMsg,
                        com.vmware.vim25.InvalidStateFaultMsg,
                        com.vmware.vim25.MigrationFaultFaultMsg,
                        com.vmware.vim25.InvalidCollectorVersionFaultMsg,
                        com.vmware.vim25.TimedoutFaultMsg
        Throws:
        com.vmware.vim25.RuntimeFaultFaultMsg
        com.vmware.vim25.InsufficientResourcesFaultFaultMsg
        com.vmware.vim25.VmConfigFaultFaultMsg
        com.vmware.vim25.InvalidDatastoreFaultMsg
        com.vmware.vim25.InvalidPropertyFaultMsg
        com.vmware.vim25.FileFaultFaultMsg
        com.vmware.vim25.InvalidStateFaultMsg
        com.vmware.vim25.MigrationFaultFaultMsg
        com.vmware.vim25.InvalidCollectorVersionFaultMsg
        com.vmware.vim25.TimedoutFaultMsg