9 Replies Latest reply on Jun 18, 2015 9:51 AM by Javik

    Moving VMs in ESXi

    bgarmon Novice

       

      Can someone help with the syntax ( or process) for how I can move a couple of virtual machines from 1 ESXi server to another ESXi over a network? I'm just not that familiar with Linux/Unix.

       

       

      This can be done offline with the vm's shutdown if that matters.

       

       

       

       

       

        • 1. Re: Moving VMs in ESXi
          tbokman Novice

          Just download and install the free VM converter tool.  Install it on a windows box that's on the same subnet as the ESXi hosts

          • 2. Re: Moving VMs in ESXi
            1x1x1 Enthusiast

             

            one way is shut down the VMs and move the files to another machine (though this might be a bit slow)

             

             

            I'm sure theres a better way

             

             

            maybe export the Virtual appliance and then import it

             

             

            • 3. Re: Moving VMs in ESXi
              bgarmon Novice

              I installed the stand-alone converter tool - it seems to have no method for me to connect to the ESXi server to get the source files. Not sure how this would be helpful as I don't want to convert them - I just need to move them.

              • 4. Re: Moving VMs in ESXi
                1x1x1 Enthusiast

                ya I'm not sure how the converter tool is relivant ether

                 

                but in the Infrastructure client you can go to File->Virtual appliance->export

                 

                the VM's have to but shutdown for this (I think their vmotion would be the way to do it live though)

                 

                 

                and I'm unsure of the impact it could have

                 

                 

                the times I've done it were to duplicate a VM (oh and it is very slow it seems it took about an hour last time)

                 

                 

                (Please award points for helpful and correct answers)

                • 5. Re: Moving VMs in ESXi
                  tbokman Novice

                  It can copy the VM from one server to another as well as convert a physical machine to a VM.  Just select convert machine and change source type to VM infrastructure VM.  Then enter host to copy from with UID and PW.  The next screen lets you pick a VM to copy (VM must be power-off).  The next screen just select to host to copy to and enter UID and PW.  This method leaves the original VM files on the copy from host so you may want to delete once you're sure everything works on the new host.

                  1 person found this helpful
                  • 6. Re: Moving VMs in ESXi
                    bgarmon Novice

                     

                    Pefect -this is exactly what I was looking for.

                     

                     

                     

                     

                     

                    Solution:

                     

                     

                    Shut down the VM

                     

                     

                    Choose File > Virtual Appliance >  Export - pick your director.

                     

                     

                     

                     

                     

                    • 7. Re: Moving VMs in ESXi
                      1x1x1 Enthusiast

                      interesting I'll have to download it for future VM moves

                      • 8. Re: Moving VMs in ESXi
                        dcyril Novice

                        Does anyone know if the current version 5.5.3 will work to move/copy VMs to the new ESXi 6.0?

                        • 9. Re: Moving VMs in ESXi
                          Javik Novice

                          I just did this last week. To move VMs between free ESXi's you need a third computer with enough disk space to hold the full size of the VM virtual disks.

                           

                          (I am not clear on this, but this process may change thin disks to thick during the move rather than being a raw disk datafile copy. I used thick in the first place for performance, so don't know if that happens or not.)

                           

                          From this 3rd computer with the large temporary storage, run vSphere client.

                           

                          Log on to the source ESXi

                          • Stop the VM to be moved
                          • Select the hypervisor at the top of the inventory and go to the Summary page
                          • In Storage section, right click on the datastore containing the VM and Browse Datastore
                          • Select the Folder containing all the VM files, and choose Download a file from this datastore to your computer
                          • Select a location on the 3rd computer for the VM files
                          • Wait ... possibly hours for it to copy over
                          • Disconnect from the source ESXi

                           

                          Log on to the target ESXi

                          • Select the hypervisor at the top of the inventory and go to the Summary page
                          • In Storage section, right click on the datastore to hold the moved VM and Browse Datastore
                          • In the root of the datastore, choose Upload files to this datastore  -> Upload Folder
                          • Select the folder on the 3rd computer with the VM files
                          • Wait ... possibly hours for it to copy over
                          • While still in the datastore browser, click on the folder containing the moved VM, find the *.VMX file for the copied VM, right click on it, and choose Add to Inventory
                          • Edit the virtual machine if you need to change the network adapters to match the new host, change memory allocation, CPU allocation, etc
                          • Run the virtual machine, and open the console window for it
                          • You are asked if you are Moving or Copying the VM. If you choose Move, the VM keeps the same ethernet MAC address as before and launches as if it's still on the original ESXi.

                           

                          Choosing Move should allow moving of virtalized domain controllers between ESXi's without breaking them. If you choose Copy, the network MAC addresses and possibly other values such as the disk SID may change, which will screw up a virtualized domain controller and your domain.