You may have found the snapshots export option on Hyper-V, but there is no such an option in VMware products. So, is there a way to achieve that in VMware? That’s what I am going to introduce in this article.
Case: Copy VM Snapshot to a new VM Environment
We have 2 separate VMWare environments. What I would like to do is take a snapshot of the current state of one of our live VMs, and use that to copy to the other VMWare environment and create a new machine there, using that as the archive of that system. Is this going to be possible/easy?
- Question from Serverfault.com
You can export checkpoints on Hyper-V starting from Windows Server 2012 R2, but there is no such an option for export snapshot VMware ESXi. After all, snapshots are just some points in time and should not be exported alone, nor used for long-term storage.
But what if you want to copy VMware snapshot to another computer? Or VMware copy snapshot to another machine? Can you export VM with snapshots? In most VMware backup solutions, you need to power off the VM and commit all the snapshots beforehand. If you export a VM with multiple snapshots, you will get a VM with only the last snapshot by importing. Also, it's not recommended to manipulate individual subdisks or snapshot profile, which may compromise the disk chain and result in data loss.
However, when you have actual needs of saving the particular state of the VM (such as testing or troubleshooting), there are still workarounds you can try to export snapshots on VMware ESXi and Workstation without losing data.
For example, you can manually copy all the files of the ESXi VM, including the snapshots, or VMware Workstation snapshot clone. In this article, I will introduce the detailed steps to achieve them.
If you are using VMware workstation, you can export snapshot by making a clone from it. But please note that you can only make a clone from snapshots taken when the VM is powered off.
If the target snapshot is taken when the VM is running, when you are trying to make a clone from it, you will receive an 'you cannot make a clone of a virtual machine or snapshot that is powered on or suspended' alert.
1. Launch VMware Workstation, and power off the original VM. Right-click on the VM name and select Snapshot > Snapshot Manager.
2. In the pop-up Snapshot Manager, select the target snapshot and click Clone to open the Clone Virtual Machine Wizard. Click Next to start.
3. Select to clone from An existing snapshot (powered off only), you can change the target snapshot here. Then click Next.
4. Select to Create a linked clone, or Create a full clone. Here I select Create a full clone and click Next.
Note: Linked clone: A linked clone is a reference to the original VM and requires less disk space to store. However, it cannot run without access to the original VM. Full clone: A full clone is a complete copy of the original VM at its current state. This VM is fully independent, but requires more disk space to store.
5. Provide a Name, and click Browse… to select a destination location for the new VM. They should be different from the original VM.
6. Click Finish to start. The progress will show on the wizard.
On VMware ESXi, there is neither a snapshot export option, nor a make clone from the snapshot option, then we need to consider other workarounds to export snapshot VMware ESXi.
Here I have summarised 2 ways. Way 1 is using effecitve backup & restore tool; Way 2 is to manually copy all the files of the VM to create an exact same VM, and then optionally revert one of the VM to a previous state. Here are the specific steps.
For those managing multiple virtual machines, copying VM folders to create a new virtual machine with snapshots seems to be troublesome. Also, snapshots are not secure for data protection which rely on the parent disk and easy to be damaged. So, what should you do to protect data security?
As we mentioned before, there is no in-built feature to export snapshots in ESXi, so you could only use a third-party tool to achieve data protection or restore VM to another host conveniently. In this part, I will use a backup software called AOMEI Cyber Backup to perform VM backup.
Batch VM Backup: batch backup large numbers of VMware ESXi VMs managed by vCenter Server or standalone ESXi hosts. Restore to another VM/host. While restoring, you can easily choose to restore to original/new location. Schedule automatic backup: You can automate the backup tasks to run daily, weekly, monthly, etc. which also offers the regular recovery points. Secure backup: It provides a more secure and stable backup than snapshot. Easy to operate: You can create a backup task with several clicks without installed any agents. Support free ESXi: AOMEI Cyber Backup supports both paid and free versions of VMware ESXi.
*You can choose to install this VM backup software on either Windows or Linux system.
▶ How to back up VMs with snapshots step-by-step:
1. Download AOMEI Cyber Backup and add vCenter or Standalone ESXi host as the source device.
2. Click Create New Task to set up a backup task.
3. Click Start Backup to execute the operation. When it's completed, you can find this task in Backup Task tab.
▶ How to restoe the backup to a new VM:
In the Version page, you can find the regular backup files, and restore the VM from any point. It is also convenient to create a new VM in another virtual environment by clicking Restore to New Location.
If you want to directly copy VM files to create a same VM with snapshots, please refer to the following steps.
1. Access vSphere Web Client, click Storage in the left inventory, and click Datastore browser on the right page.
2. Click Create directory in the pop-up window, and provide a Directory name for the new VM. Click Create Directory to confirm.
3. Back to the Datastore browser, find the folder of the original VM and click Copy on the toolbar to copy all files in it to the new folder you just created.
4. Close Datastore browser, and click Virtual Machines in the left inventory. Click Create/Register VM on toolbar to open the wizard.
5. On Select creation type page, select Register an existing virtual machine and click Next.
6. On Select VMs for registration page, click Select one or more virtual machines, a datastore or a directory, and select the newly created folder. Click Next.
7. On Ready to complete page, click Finish to close the wizard.
8. Back to Virtual Machines, now you can see the newly copied VM with the same name as the old one, that’s because the name comes from the .vmx file in the folder. You can right-click on the VM name and Rename it.
9. Power on the new VM you just copied, select I copied it and click Answer in the pop-up window.
Exporting snapshots manually takes more time and is likely to fail if the snapshot size is too large.
VMware products currently provide no export snapshot VMware ESXi option. But you can use a professional software to offer regular recovery points like snapshots.
In this article I introduced the specific steps of how to manually copy all of the ESXi VM files and VMware Workstation snapshot clone, as well as how to create VMware backup schedule for data security. You can copy VMware snapshot to another computer by copying all VM files.