You can take one or more snapshots of a virtual machine to capture the settings state, disk state, and memory state at specific times. When you take a snapshot, you can also quiesce the virtual machine files and exclude the virtual machine disks from snapshots.
When you take a snapshot, other activity that is occurring in the virtual machine might affect the snapshot process when you revert to that snapshot. The best time to take a snapshot from a storage perspective, is when you are not incurring a large I/O load. The best time to take a snapshot from a service perspective is when no applications in the virtual machine are communicating with other computers. The potential for problems is greatest if the virtual machine is communicating with another computer, especially in a production environment. For example, if you take a snapshot while the virtual machine is downloading a file from a server on the network, the virtual machine continues downloading the file and communicating its progress to the server. If you revert to the snapshot, communications between the virtual machine and the server are confused and the file transfer fails. Depending on the task that you are performing, you can create a memory snapshot or you can quiesce the file system in the virtual machine.
- Memory Snapshots
-
The default selection for taking snapshots. When you capture the virtual machine's memory state, the snapshot retains the live state of the virtual machine. Memory snapshots create a snapshot at a precise time, for example, to upgrade software that is still working. If you take a memory snapshot and the upgrade does not complete as expected, or the software does not meet your expectations, you can revert the virtual machine to its previous state.
When you capture the memory state, the virtual machine's files do not require quiescing. If you do not capture the memory state, the snapshot does not save the live state of the virtual machine and the disks are crash consistent unless you quiesce them.
- Quiesced Snapshots
-
When you quiesce a virtual machine, VMware Tools quiesces the file system of the virtual machine. A quiesce operation ensures that a snapshot disk represents a consistent state of the guest file systems. Quiesced snapshots are appropriate for automated or periodic backups. For example, if you are unaware of the virtual machine's activity, but want several recent backups to revert to, you can quiesce the files.
If the virtual machine is powered off or VMware Tools is not available, the Quiesce parameter is not available. You cannot quiesce virtual machines that have large capacity disks.
Change Disk Mode to Exclude Virtual Disks from Snapshots
You can set a virtual disk to independent mode to exclude the disk from any snapshots taken of its virtual machine.
PrerequisitesPower off the virtual machine and delete any existing snapshots before you change the disk mode. Deleting a snapshot involves committing the existing data on the snapshot disk to the parent disk.
You can take a memory snapshot of a virtual machine with an independent disk, but the snapshot cannot be restored. The main purpose of these snapshots is to capture the state of a virtual machine for further analysis through the Vmss2core or similar tools.
- Right-click a virtual machine in the inventory and select Edit Settings.
- On the Virtual Hardware tab, expand Hard disk, and select an independent disk mode option.
Option Description Dependent Dependent mode is the default disk mode. When you take a snapshot of a virtual machine, dependent disks are included in the snapshot. When you revert to the previous snapshot, all data are reverted to the point of taking a snapshot.
Independent - Persistent Disks in persistent mode behave like conventional disks on your physical computer. All data written to a disk in persistent mode are written permanently to the disk even if you revert a snapshot. When you power off or reset a virtual machine, the disk and all its snapshots are preserved.
Independent - Nonpersistent Disks in nonpersistent mode behave like read-only disks. Changes to disks in nonpersistent mode are discarded when you power off or reset the virtual machine. With nonpersistent mode, you can restart the virtual machine with a virtual disk in the same state every time. Changes to the disk are written to and read from a redo log file that is deleted when you power off or reset the virtual machine, or when you delete a snapshot.
- Click OK.
Take a Snapshot of a Virtual Machine
You can take a snapshot when a virtual machine is powered on, powered off, or suspended. If you are suspending a virtual machine, wait until the suspend operation finishes before you take a snapshot.
When you create a memory snapshot, the snapshot captures the state of the virtual machine memory and the virtual machine power settings. When you capture the virtual machine memory state, the snapshot operation takes longer to complete. You might also see a momentary lapse in response over the network.
When you quiesce a virtual machine, VMware Tools quiesces the file system in the virtual machine. The quiesce operation pauses or alters the state of running processes on the virtual machine, especially processes that might modify information stored on the disk during a revert operation.
Application-consistent quiescing is not supported for virtual machines with IDE or SATA disks.
Prerequisites
- If you are taking a memory snapshot of a virtual machine that has multiple disks in different disk modes, verify that the virtual machine is powered off. For example, if you have a special purpose configuration that requires you to use an independent disk, you must power off the virtual machine before taking a snapshot.
- To capture the memory state of the virtual machine, verify that the virtual machine is powered on.
- To quiesce the virtual machine files, verify that the virtual machine is powered on and that VMware Tools is installed.
- Verify that you have the privilege on the virtual machine.
Procedure
- In the vSphere Client, navigate to a virtual machine and click the Snapshots tab.
- Click Take Snapshot.
Result: The Take snapshot dialog box opens.
- Enter a name for the snapshot.
- (Optional) Enter a description for the snapshot.
- (Optional) To capture the memory of the virtual machine, select the Snapshot the virtual machine's memory check box.
- (Optional) To pause running processes on the guest operating system so that file system contents are in a known consistent state when you take a snapshot, select the Quiesce guest file system (requires VMware Tools) check box.
Note: You can quiesce the virtual machine files only when the virtual machine is powered on and the Snapshot the virtual machine's memory check box is deselected.
For more information about the virutal machine behavior when you quiesce a virtual machine, see the KB article https://kb.vmware.com/s/article/5962168.
- Click Create.