Search
StarWind is a hyperconverged (HCI) vendor with focus on Enterprise ROBO, SMB & Edge

How to Automatically Delete Snapshots in VMware vSphere 8 Update 3

  • July 23, 2024
  • 11 min read
IT and Virtualization Consultant. Vladan is the founder, and executive editor of the ESX Virtualization Blog at vladan.fr. He is a VMware VCAP-DCA and VCAP-DCD, and has been a vExpert from 2009 to 2023.
IT and Virtualization Consultant. Vladan is the founder, and executive editor of the ESX Virtualization Blog at vladan.fr. He is a VMware VCAP-DCA and VCAP-DCD, and has been a vExpert from 2009 to 2023.

VMware vSphere 8 Update 3 has introduced a new feature that allows administrators to automatically delete snapshots on virtual machines (VMs). This feature is a welcome addition, as it eliminates the need for additional tools or scripts.

In this blog post, we will explore how to use this feature in detail and talk about some additional features that are part of the vSphere 8 U3 release.

Understanding Snapshots

Snapshots are a powerful feature in VMware vSphere that allows administrators to save the state of a virtual machine before installing patches or updates. However, retaining old snapshots can consume significant disk space and potentially lead to errors. Therefore, it’s important to manage and delete old snapshots regularly.

A leftover snapshot can be also resulting some backup software which traditionally uses snapshot technology even though, since few years we have heard less and less problems like this. But nevertheless, snapshots should not be kept for long periods of time and should be deleted/cleaned on regular basis. Having a way to do that automatically adds more to the security and resiliency of your infrastructure.

New Snapshot Deletion Feature in vSphere 8 Update 3

With vSphere 8 Update 3, you can now schedule a task to automatically delete snapshots for virtual machines that are older than a certain number of days. This feature can be found in the Snapshots tab for a virtual machine.

How to Schedule a Task to Delete Snapshots

Open your vSphere client and go and navigate to a virtual machine in the inventory and click the Configure tab.

Select Scheduled Tasks and from the New Scheduled Task drop-down menu select Delete Snapshots.

The Schedule New Task window opens.

On the Scheduling Options page set the scheduling options.

After clicking “schedule a task”, you will be taken to the Scheduled Tasks screen.

Click the “New Scheduled Task” drop-down and select “Delete snapshots”.

Schedule New task deletion wizard

Schedule New task deletion wizard

The “Schedule New Tasks (Delete Snapshots)” wizard will launch. Here, you can configure the following:

  • Task name
  • Description
  • Target
  • Run frequency
  • Email notification upon completion

The run frequency options include options such as: Once, After vCenter startup, Hourly, Daily, Weekly, Monthly. After selecting one of these options, the configuration for the specific interval will change based on your selection.

Using PowerCLI

In addition to the vSphere Client, you can also use PowerCLI to invoke the API to perform the same task. The RemoveAllSnapshots_Task API method can be used with the retentionDays parameter to specify the number of days.

vSphere 8 Update 3 Release Overview

VMware vSphere 8 Update 3 was released on June 25, 20241. This update is a significant one, and we have already reported in depth in this article on StarWind blog here – What’s New in VMware vSphere 8.0 Update 3. There are many new features and capabilities that enhance the platform’s functionality.

Key Features of vSphere 8 Update 3

DPU/SmartNIC High Availability with VMware vSphere Distributed Services Engine – This feature adds support for 2 data processing units (DPUs) to provide high availability or increase offload capacity per ESXi host23. Dual-DPU systems can use NVIDIA or Pensando devices.

vSphere IaaS Control Plane Support for vSAN Stretched Clusters – vSphere 8.0 Update 3 adds support for vSphere IaaS control plane, formerly known as vSphere with Tanzu, on vSAN stretched clusters. This capability is available only for greenfield installations of the IaaS control plane on stretched vSAN clusters.

New Virtual Machine Compute Policy for Best Effort Virtual Machine Evacuation – This feature adds a compute policy for best effort evacuation of virtual machines on ESXi hosts that are entering maintenance mode. When the host enters maintenance mode, all VMs are shut down. If shutdown fails, the VMs are powered off.

Embedded vSphere Cluster Service (vCLS) – vSphere 8.0 Update 3 introduces a redesign of vCLS to Embedded vCLS, which utilizes vSphere Pod technology.

vSphere Fault Tolerance (FT) Metro cluster support – it’s been quite long tims since vSphere and FT has had this limitation. Now with a simple check box, you can Enable Metro Cluster FT.

Enable Metro Cluster Fault Tolerance feature

Enable Metro Cluster Fault Tolerance feature

The primary FT VM is running on the host group site and the secondary VM is automatically placed on the opposite (remote) site.

If you have a host failure on the primary site, the secondary FT VM will take over automatically. Then another host within the local site is selected for a secondary VM, and you still have 2 VMs in FT running.

If you have a site failure, then the affected FT VMs running normally, but without FT protection. Once the site is up again, everything is back to normal and FT protection recovers.

These features, among others, make vSphere 8 Update 3 a robust and versatile platform for managing virtual environments. Whether you’re looking to increase your system’s high availability, streamline your IaaS control plane, or improve your virtual machine management, vSphere 8 Update 3 has you covered.

vSphere 8 Update 3 includes several security updates

Additionally, the U3 secures your environment with the latest releases of security patches that are necessary to keep your environment secure.

Resolved Vulnerabilities – This release resolves CVE-2024-37085 and CVE-2024-370861. For more information on these vulnerabilities and their impact on VMware products, see VMSA-2024-00131.

Profile-Based Configuration for TLS and Cipher Suites – The update introduces profile-based configuration for TLS and cipher suites, simplifying compliance and security configurations through API or PowerCLI scripts.

Security Hardening Guidance for vSAN – Easy to understand hardening guidance has now been added for vSAN services.

TLS1.3 Support – This update delivers the ability to configure security best practices using the latest modern ciphers.

Automated Rotation of Expiring Supervisor Certificates – vSphere now automates the rotation of expiring Supervisor certificates, which can be a pain to have to rotate manually. It helps reduce the manual steps needed before rotation and enhances security. This feature also has an alarm that alerts administrators only if the auto-renewal process fails.

These updates enhance the security of your vSphere environment, making it more robust and secure against potential threats.

Final Words

The new snapshot deletion feature in vSphere 8 Update 3 is a small but powerful tool that can greatly simplify snapshot management. By allowing administrators to automatically delete old snapshots, it helps ensure that your vSphere environment runs optimally and reduces the risk of errors due to excessive disk space consumption. Whether you’re using the vSphere Client or PowerCLI, managing your snapshots has never been easier.

Hey! Found Vladan’s article helpful? Looking to deploy a new, easy-to-manage, and cost-effective hyperconverged infrastructure?
Alex Bykovskyi
Alex Bykovskyi StarWind Virtual HCI Appliance Product Manager
Well, we can help you with this one! Building a new hyperconverged environment is a breeze with StarWind Virtual HCI Appliance (VHCA). It’s a complete hyperconverged infrastructure solution that combines hypervisor (vSphere, Hyper-V, Proxmox, or our custom version of KVM), software-defined storage (StarWind VSAN), and streamlined management tools. Interested in diving deeper into VHCA’s capabilities and features? Book your StarWind Virtual HCI Appliance demo today!