What are VMware Snapshots & How to Work with Them Properly?

Do you know what are snapshots in VMware? VMware snapshots are convenient as quick failsafe rollback points, but have many limitations. In this article I will introduce you how they work, and how to use them properly.

Crystal

By Crystal / Updated on March 8, 2023

Share this: instagram reddit

VMware snapshots overview

A VM snapshot preserves the state and data of a VM at a specific point in time. The state includes the VM’s power state (for example, powered-on, powered-off, suspended). The data includes all of the files that make up the VM. This includes disks, memory, and other devices, such as virtual network interface cards.

VMware snapshots are popular as a quick failsafe measure. In Hyper-V environments, they are also known as checkpoints since Windows Server 2012 R2.

How to properly work with VMware snapshots

Is a VMware snapshot the same as a backup?

Many users tend to achieve VMware backup by snapshot, but strictly speaking, they are 2 different concepts.

Snapshots can be used to roll back a virtual machine, but cannot be used as a backup. To be specific, a VM backup is a complete copy independent of the parent disk, which is not affected and can be used to recover a VM. But a virtual machine snapshot is dependent on the parent disk, and not sufficient to recover a virtual machine if the parent disk is deleted or if the virtual or physical infrastructure fails.

Besides, all changes made to a VM after taking a VM snapshot are stored in the incremental disk file. Therefore, snapshots also take up a lot of disk space, and keeping them for a long time can affect the performance of the virtual machine. However, virtual machine backups can be kept for a long time without affecting the original virtual machine.

Simply put, VMware snapshot cannot replace backup. But you can combine the 2 as a VM protection strategy.

Snapshot or backup?

How do snapshots work in VMware

Taking a VMware snapshot, the following files will be created:

  • -.vmdk: The -flat.vmdk file that contains the raw data in the base disk.
  • -delta.vmdk: The temporary delta disk file created to store all the changes made to the VM since the snapshot was taken. Represented in the format of -00000x.vmdk.
  • .vmsd: A database file of the VM’s snapshot information and the primary source of information for the Snapshot Manager. The file contains line entries which define the relationships between snapshots as well as the child disks for each snapshot.
  • Snapshot.vmsn: A memory file that contains the current configuration and optionally the active state of the virtual machine, allowing you to revert to a running state of the VM.

When taking a VMware snapshot, the original virtual disk file will become read-only, and a temporary delta disk which points to it will be created, to store all the changes made to the VM afterward.

As more writes are made to the delta disk, it can grow large enough to fill an entire datastore. After the snapshot is deleted, all changes will be merged into the original .vmdk file, and it will return to read-write mode.

VM snapshot files

When to use VMware snapshots

VMware snapshots can be used as quick failsafe rollback points, to reduce the hassle of creating multiple VMs.

Generally, VMware snapshots are used for development and testing purposes. For example, taking snapshots before performing patches, upgrades, tests and other unsafe operations.

However, they are not recommended to be used in production environments, since running VM on snapshots for a long time can lead to instability and data loss.

VMware snapshot best practices

Although convenient, VMware snapshots have limitations in practical use. For example, snapshots can have a negative impact on the performance of VM systems.

Performance degradation depends on how long you keep the snapshots, how deep the snapshots tree is, and how many changes you have made to the VM since you took the snapshot.

For better working with VMware snapshots, here I summarized 3 best practices.

Tip 1. Do not use VMware snapshots as backups

VM snapshot vs backup is a long-confusing issue for VM users. The accepted conclusion is that snapshots cannot be used as backups.

As above stated, while VM backup is an independent copy of the VM, and can be safely stored offsite to the cloud or other locations, snapshots depend on the parent disk. If the base disks are deleted, the snapshot files are not sufficient to restore a VM.

Tip 2. Use only 2-3 snapshots

When you create a snapshot for the first time, the first child disk is created from the parent disk. Successive snapshots generate new child disks from the last child disk on the chain.

A maximum of 32 snapshots are supported in a chain. However, for a better performance please use only 2 to 3 snapshots.

Tip 3. Do not use a single snapshot for more than 72 hours

Generally, you need to reserve 20-30% extra storage for a single snapshot. As more changes you made to the VM after a snapshot, the delta disk file can even run out of space, and affect the performance of your VM system.

Therefore, please delete the snapshots in time to merge the changes to the parent disk when they are no longer useful, or before creating backups of your VM.

How to properly work with VMware snapshots

Now you have known when should you take VMware snapshots, and how to keep them in optimal use. The next thing you need to know is the specific steps of the basic VMware snapshots operations.

In this section, I will demonstrate how to perform the basic operations of VMware ESXi snapshots as an example.

Case 1. How to take a snapshot in vSphere Web Client

1. Access to vSphere Web Client. Right-click on the VM name in the inventory and select Snapshots > Take Snapshot…

Take snapshot

2. In the pop-up window, provide a Name and optionally a Description for the snapshot. You can Edit them later in Snapshot Manager.

3. There are 2 options to check:

  • Snapshot the virtual machine’s memory: record the VM’s memory, allowing you to roll back the VM to the exact running state when the snapshot was taken, but takes longer. If you leave this option unchecked, then the VM will be powered-off after you roll back.
  • Quiesce guest file system (needs VMware tools installed): pause the state of the processes that are running, or may modify the information stored on disk when the snapshot was taken, to guarantee the consistency. Quiescing and Memory snapshots are mutually exclusive.

Provide name and description for VM

4. Click OK to take the snapshot. You can see the progress in Recent Tasks.

Case 2. How to revert to a snapshot

1. Access to vSphere Web Client. In this step, operations are different according to different needs. 

✦ If you want to revert to the latest snapshot: Right-click on the VM name and select Revert to Latest Snapshot.

Revert to latest snapshot

✦ If you want to revert to another previous snapshot: Right-click on the VM name and select Manage Snapshots…

Manage snapshots

Select the snapshot you want to revert in Snapshot Manager, and click Revert to.

Revert to

2. It will pop up a Confirm window notifying the loss of the current state. If it is a memory snapshot, then there will be one more option to suspend this VM when reverting to selected snapshot. You need to manually power on the VM later if you check this option.

Confirm revert to snapshot

3. Click Yes to revert to the selected VMware snapshot. In Snapshots Manager you can see the current state represented by You are here.

Case 3. How to delete one or all VMware snapshots

1. Access to vSphere Web Client. Right-click on the VM name and select Manage Snapshots…

Manage snapshots

2. In this step, operations are different according to different needs.

✦ If you want to delete one snapshot: Select the target snapshot and click Delete. Click Yes in the pop-up Confirm window.

Delete one snapshot

✦ If you want to delete all snapshots: Click Delete All in Snapshot Manager and click Yes in the pop-up Confirm window.

Delete all snapshots

3. Click Close to exit the Snapshot Manager.

How to properly backup VMware ESXi virtual machines

There are mainly 4 VMware backup solutions to create independent and complete VMware VM backups.

  • Manually copy/download VM files: using the copied (or download on ESXi) VM files you can create a new VM on the original or another host.
  • Export VM to OVF/OVA templates: By exporting VMs to compressed Open Virtualization Format (OVF) files, you can achieve faster downloads, and import VMs to the original or another host.
  • Clone VMs: clone is a way to create multiple same VMs that are immediately usable.
  • Backup VMs using dedicated backup tools: currently this is the only way to automatically backup multiple VMware VMs.

Today, dedicated backup tools have been developed comprehensively in VM backups, compensating for many tasks that VMware's built-in features can't accomplish, and are therefore widely accepted by VM users.

For example, AOMEI Cyber Backup is a free VMware backup software, which allows you to auto backup multiple VMs on both paid and free versions of VMware ESXi. Next I will demonstrate how to do that as an example. You can click the following button to download the freeware:

Download FreewareVMware ESXi & Hyper-V
Secure Download

*You can choose to install this VM backup software on either Windows or Linux system.

3 easy steps to backup multiple VMware ESXi VMs

1. Bind Devices: Access to AOMEI Cyber Backup web client, navigate to Source Device > VMware > + Add VMware Device to add vCenter or Standalone ESXi host as the source device, and then click > Bind Device.

Note: This step is only needed when you bind the host for the first time, you do not need to repeat after successful binding.

Add VMware ESXi host

2. Create Backup Tasks: Navigate to Backup Task > + Create New Task, and provide Task Name, Backup Type, Device, Target, and Schedule as needed.

Create a VMware ESXi backup task

  • Device: cover multiple VMs on the host in one backup task.
  • Target: you can select to back up to a local path, or to a network path. Used paths will be saved in Favorite Storage for handy selection.
  • Schedule: you can choose to perform full, differential or incremental backup, and automate execution daily, weekly or monthly according to the frequency you specified.

Schedule type

3. Start Backup: Click Start Backup to select to Add the schedule and start backup now, or Add the schedule only.

Start Backup VMware ESXi VMs

Created backup tasks will be listed separated for further log checking, task changing, or restoring.

While the Free Edition covers most of VM backup needs, you can also upgrade to enjoy:
Batch VM Backup: batch backup large numbers of VMs managed by vCenter Server or standalone ESXi hosts.
Backup cleanup: Configure a retention policy to auto delete old backup files and save storage space.
Restore to new location: Create a new VM in the same or another datastore/host directly from the backup, saves the trouble of re-configuring the new VM.

Backup Cleanup

Summary

Many people confuse VMware backup with snapshots. In fact, they are 2 different things. Although VMware snapshots are convenient for quickly rolling back the VM to a specific point in time, they cannot replace backups, and need to be used properly to maintain the VM system performance.

In this article, I introduced what are snapshots and the best practices to use them, including the detailed steps of how to create, revert, and delete them. Snapshots cannot replace backups, but using them in conjunction with backups can greatly improve your work efficiency.

To properly backup VMware ESXi VMs, you can choose AOMEI Cyber Backup to help you schedule automatic backup tasks for multiple VMs. Except for VMware ESXi VMs, it also supports Microsoft Hyper-V.

Crystal
Crystal · Editor
Crystal is an editor from AOMEI Technology. She mainly writes articles about virtual machine. She is a positive young lady likes to share articles with peolpe. Off work she loves travelling and cooking which is wonderful for life.