How to check the health status of a vmdk file
search cancel

How to check the health status of a vmdk file

book

Article ID: 282643

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

This article describes:

1. How to check the health status of a VMDK.
2. How to repair a disk that contains errors.

 

Environment

ESXi 7.x

ESXi 8.x

Resolution

Please follow these steps to check and potentially repair the health status of the VMDK file:


1. Check VMDK Health Status
Execute the following command to check the health of the VMDK file:

vmkfstools -x check /vmfs/volumes/datastore/VM_Folder/VirtualMachine.vmdk

* If the disk is healthy, the output will be: Disk is error free
* If the disk requires attention, the output will be: Disk needs repair

 

2. Repair VMDK (If Necessary)
If the check indicates that the disk needs repair, ensure that there is a current backup of the VMDK file before proceeding.

To initiate the repair process, run this command:

vmkfstools -x repair /vmfs/volumes/datastore/VM_Folder/VirtualMachine.vmdk

A successful repair will result in the output: Disk was successfully repaired