The Hyper-V version available in Windows Server 2016 and Windows 10 has got a new feature called Production Checkpoints. Checkpoints (previously known as snapshots) appeared in Hyper-V in Windows Server 2008 and represented a mechanism for saving the current state of the virtual machine (saving the states of a disk, memory, processors and devices). If necessary, an administrator can roll back a VM to its state at the moment when this point has been created. This type of a checkpoint doesn’t depend on the guest VM, which doesn’t know anything about the checkpoint. The main drawback of checkpoints is their inability to provide consistency of applications running inside the VM (SQL Server database, Active Directory, Exchange, etc.). Thus, Microsoft recommends to use standard Hyper-V production checkpoints (we’ll call them Standard Checkpoints) only in test or lab environments.
Due to their integration with the guest OS using VSS (in Windows) or fsfreeze (in Linux), Production Checkpoints in Windows Server 2016 allow to get a consistent state of a virtual machine (obviously, if an application supports shadow copying via VSS).
When a VM checkpoint is created in Hyper-V 2016, new Production Checkpoints are used by default, and if they are not supported on any reasons, Standard Checkpoints are used.
The checkpoint type is set in Hyper-V Manager in the Checkpoints section of the Settings tab.
You can switch the modes of Hyper-V checkpoints creation using the following PowerShell commands:
Set-VM -Name Lon-SQL1 -CheckpointType Disabled
Set-VM -Name Lon-SQL1 -CheckpointType Standard
Set-VM -Name Lon-SQL1 -CheckpointType Production
Set-VM -Name Lon-SQL1 -CheckpointType ProductionOnly
CheckPoint-VM –Name Lon-SQL1
When creating a Production Checkpoint, in the Application log of the guest VM you can find the events showing the start and finish of creating the application consistent state with VSS.
After rollback to the Production Checkpoint created earlier, you must manually turn on the VM. Both the guest OS and the running application will consider that earlier they shut down correctly.
However, you shouldn’t forget that Hyper-V checkpoints are not the full-featured backup tool. Their scope is short-term tasks (testing releases, updates, changes, etc.).