WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
    • VMware Cloud Foundation 9.1
    • VMware Cloud Foundation 9.0
  • VKS
  • Homelab
    • Hardware Options
    • Hardware Reviews
    • Lab Deployment Scripts
    • Nested Virtualization
    • Homelab Podcasts
  • VMware Nostalgia
  • Apple
You are here: Home / ESXi / Quick Tip: The Fastest Way to Clear Partitions for ESX Reinstallation

Quick Tip: The Fastest Way to Clear Partitions for ESX Reinstallation

08.15.2026 by William Lam // Leave a Comment

I often redeploy my VMware Cloud Foundation (VCF) lab environment for a variety of reasons, from testing customer scenarios to testing the next version of our software. Because I have fully automated the ESX installation and configuration process in my lab, reinstalling ESX is a trivial task that takes less than 5 minutes from power-on to a fully configured system ready for VCF.

When reinstalling ESX, especially on systems configured with NVMe Tiering, vSAN, and local VMFS storage, the real challenge is clearing the existing partitions so the system is ready for a fresh installation. Traditionally, this can involve several manual steps and, in some cases, booting from a Linux live CD to remove stubborn partitions.

Given how frequently I redeploy my environment, I have developed the following workflow that consistently cleans up the various storage configurations without requiring a separate live CD environment. As I was performing yet another ESX reinstallation while writing this post, I realized I had never documented my workflow, so I thought I would share it in case it helps others.

Step 1 - Power off all virtual machines, then log in to the ESX Host Client and permanently delete the virtual machines.

Step 2 - Place the ESX host into Maintenance Mode. For vSAN-enabled hosts, select No Data Migration.

Step 3 - If NVMe Tiering is enabled on the ESX host, delete the NVMe Tiering partition.

For ESX 9.1, use the following command:

esxcli memtier config delete

For ESX 9.0, use the following command:

esxcli system tierdevice -d /vmfs/devices/disks/<disk>

Step 4 - If the ESX host has been configured with vSAN ESA, use the vdq utility to identify the vSAN disk and then clear the vSAN partition.

vdq -q
esxcli vsan storagepool remove -d /vmfs/devices/disks/<disk>

Step 5 - Identify the ESX installation device by running the following command. Look for the storage device that contains the ESX partition layout, including the two bootbank partitions, and make a note of the device name.

ls -l /vmfs/devices/disks


We can inspect the device to confirm the ESX partition by using the following command:

partedutil getptbl /vmfs/devices/disks/<disk>


Finally, we will delete partition 1,5,6 & 8 which will be the minimum to be able to reboot and reinstall ESX whether that is manual or through automated process.

partedutil delete /vmfs/devices/disks/<disk> X

Categories // ESXi Tags // vSphere 9.0, vSphere 9.1

Thanks for the comment!Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • Quick Tip: The Fastest Way to Clear Partitions for ESX Reinstallation 08/15/2026
  • Quick Tip: Reducing High CPU Utilization in VCF Automation (VCFA) on AMD Zen4/Zen5 CPUs 08/12/2026
  • VCF 9.1 - Quick Tip: Optimized Workflow for Configuring Distributed Transit Gateway (DTGW) with NSX Virtual Network Appliance (VNA) 08/11/2026
  • Quick Tip: Selective ESX Host Patching in VCF 9.1 08/10/2026
  • Playing with Zero Touch Provisioning (ZTP) in vSphere 9.1 using an ASUS NUC 08/07/2026
Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.

To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2026

Loading Comments...