Source:How to Remove Hyper-V Backup Checkpoint: Difference between revisions

From SEPsesam
(Marked this version for translation)
mNo edit summary
Line 5: Line 5:
<!--T:100-->
<!--T:100-->
{{Copyright SEP AG en}}
{{Copyright SEP AG en}}
{{Navigation_latest|release=[[Special:MyLanguage/SEP_sesam_Release_Versions|4.4.3/4.4.3 ''Beefalo'']]|link=[[Special:MyLanguage/SEP_sesam_Documentation#previous|documentation archive]]}}<br /></noinclude></translate>
{{Navigation_latest|release=[[Special:MyLanguage/SEP_sesam_Release_Versions|4.4.3/4.4.3 ''Beefalo'']]|link=[[Special:MyLanguage/SEP_sesam_Documentation#previous|documentation archive]]}}</div></noinclude></translate><br />
<translate>==About Hyper-V checkpoints (snapshots)== <!--T:91--></translate>
<translate>==About Hyper-V checkpoints (snapshots)== <!--T:91--></translate>
<noinclude><div class="boilerplate metadata" id="Additional resources" style="background-color:#ecedf1; color:#8695a7; border: 1px ridge #cdd3db; margin: 0.5em; padding: 0.5em; float: right; width: 35%; "><center><b>
<noinclude><div class="boilerplate metadata" id="Additional resources" style="background-color:#ecedf1; color:#8695a7; border: 1px ridge #cdd3db; margin: 0.5em; padding: 0.5em; float: right; width: 35%; "><center><b>

Revision as of 13:33, 14 October 2019

Other languages:

Template:Copyright SEP AG en

Docs latest icon.png Welcome to the latest SEP sesam documentation version 4.4.3/4.4.3 Beefalo. For previous documentation version(s), check documentation archive.


About Hyper-V checkpoints (snapshots)

Hyper-V checkpoints, formerly known as Hyper-V snapshots (the correct term only for older systems, such as Windows Server 2008 and 2012, but no longer used for Windows Server 2012 R2 or later), are a point-in-time copy of a VM. As of Windows 10 Hyper-V, there are two different checkpoint types: Standard and Production. The latter are the default checkpoint type for all newer OS versions (Windows Server 2016 and Windows 10). For details, check Microsoft article Using checkpoints to revert virtual machines to a previous state.

SEP sesam uses production checkpoints when performing Hyper-V FULL or INCR backups to create a data-consistent backup of the VM. For this purpose, Windows Volume Shadow Copy Service (VSS) or Linux file system freeze are used. When a checkpoint is created, the following files are created in the VM's checkpoint folder: a VM configuration file, VM saved state files, and checkpoint differencing disks (automatic virtual hard disk files – .AVHD or .AVHDX).

At the end of the backup, the checkpoint and associated .AVHDX files should be merged and removed; backup should only keep the newer .AVHDX file at the end of each backup job. However, sometimes checkpoints get broken, e.g., Windows Server leaves a virtual machine in a locked or backup state even after backup is complete, or the removal of a checkpoint is blocked for some other reason. This may create problems if you try to release space on your Hyper-V host or when you try to modify the VM (e.g., to edit the VM settings in order to expand the file server’s storage), as no modification is allowed as long as there is a checkpoint associated with the VM.

In such case, you have to remove the lingering recovery checkpoints manually by using Powershell. You can find more details on working with checkpoints in the TechGenix article Managing Hyper-V From the Command Line.

Removing checkpoints manually

Deleting checkpoints can help create space on your Hyper-V host, but they have to be properly removed by using PowerShell Remove-VMSnapshot (not GUI). For more details and examples on used commands, check Microsoft PowerShell documentation Remove-VMSnapshot.

  1. On your Hyper-V host, open PowerShell as an Administrator and run the following command:
  2. Get-VMSnapshot -ComputerName "My_Hyper-V_Host" -VMName "VM_with_backup_checkpoint" where "VM_with_backup_checkpoint" represents the actual name of your VMs as seen in the Hyper-V Manager on the host and "My_Hyper-V_Host" represents the name of your Hyper-V host. The checkpoint information will be shown.
  3. Use Remove-VMSnapshot command to remove a checkpoint and merge all data:
  4. Get-VMSnapshot -ComputerName "My_Hyper-V_Host" -VMName "VM_with_backup_checkpoint" | Remove-VMSnapshot However, sometimes you don't want to remove all the checkpoints as there may be some that need to be retained. Is such case, you can only remove the backup checkpoints by using the following command: Get-VMSnapshot -ComputerName "My_Hyper-V_Host" -VMName "VM_with_backup_checkpoint" -SnapshotType Recovery | Remove-VMSnapshot

You can check the merging process in the GUI; once finished, the .AVHDX files are deleted and should no longer be in the storage location.