RecoverySoftware

Recovering Data from VMWare vSphere ESXi Virtual Machines

You can lose Datastore data through a user’s error or a hypervisor failure. How to recover data of a VMWare vSphere ESXi virtual machine? Below, we will try to explain what should be done in case it happened.

Recovering Data from VMWare vSphere ESXi Virtual Machines

Contents

  1. Where VMWare ESXi stores its virtual machine files
  2. Why VMFS Datastore can be deleted
  3. Connecting VMWare ESXi Datastore
  4. How to recover data from a VMWare ESXi virtual machine using data recovery software
  5. How to recover data from a virtual disk (VMDK) file

Where VMWare ESXi stores its virtual machine files

By default, ESXi keeps virtual machine files in the same directory as virtual machine configuration files. For this purpose, ESXi creates storage spaces (Datastore) on VMFS partitions of the hard disk.

You can use a browser to learn the location of such files.

When connected to ESXi, hypervisor storage elements are shown in the Storage tab.

Inside VMFS Datastore, you can find folders with the names of virtual machines that contain the files of such machines.

Select the storage element you need. Open Datastore browser. Among other files, you will see these:

You can find the location of virtual machine files by using certain commands. To do it:

  1. Connect to ESX with the help of Secure Shell (SSH)
  2. Run the command
    find /vmfs -name "*.vmx"

The saving path for a specific machine can be found in the Virtual Machines tab, in the machine settings. Click on the settings button. Switch to VM Options.

Under General Options, look for the line VM Working Location.

Why VMFS Datastore can be deleted

One of the reasons why a virtual machine on VMWare ESXi may refuse to boot is certain problems with its VMFS Datastore. It cannot be detected by the ESXi server because of:

As a result, you can lose the VMFS Datastore and therefore lose all virtual machine data which it contains. In such cases you can try and recover the storage.

Let’s explore some options in detail.

Connecting VMWare ESXi Datastore

If your VMWare ESXi Datastore is lost, damaged, or cannot be detected – for example, after some RAID adapter settings were changed – you can mount it again.

To do it, you need to connect to the ESXi server by SSH. In the console, type this command:

esxcfg-volume -l

It brings out the Datastore list like this:

VMFS UUID/label: 01234567-01234567-abcd-0123456789ab/datastore1

Where 01234567-01234567-abcd-0123456789ab is the Datastore identifier.

Connect the Datastore with this command:

esxcfg-volume -M 01234567-01234567-abcd-0123456789ab

and paste your identifier instead of 01234567-01234567-abcd-0123456789ab.

If the operation is successful, you will see this notification: “Persistently mounting volume 01234567-01234567-abcd-0123456789ab.” And that is all. You don’t need to restart the ESXi server.

How to recover data from a VMWare ESXi virtual machine using data recovery software

Let’s explore data recovery from Datastore with the use of RS Partition Recovery. In its virtual environment, the program mounts VMDK virtual disks used by ESXi machines, and provides access to their contents, including deleted files.

This program allows you to recover data from dynamic and fixed-size virtual hard disks, restore points and operating system snapshots.

To recover data from an ESXi machine, you need to connect the physical disk of its storage to a computer with a desktop-type operating system.

Note: if a RAID array is used as ESXi storage, you need to connect all disks within this array to the computer and use a software product that supports RAID – RS RAID Retrieve.

RS Partition Recovery lets you recover data from VMFS partitions.

Start RS Partition Recovery.

RS Partition Recovery

All-in-one data recovery software

In the Drive Manager, choose the VMFS volume containing Datastore, or the entire hard disk.

To analyze it and search for files, right-click on the VMFS volume and choose the scan type.

When you see the search results, go to the partition where virtual machine files used to be stored.

Select the required data and click Recover to save the data.

When the recovery operation is over, the virtual machine files will be placed into the directory according to the path you have given.

The recovered data can be imported to an existing virtual machine, or you can create a new one and select the .vmdk file as the hard disk for such new virtual machine.

How to recover data from a virtual disk (VMDK) file

In the main window of RS Partition Recovery, select Tools – Mount Disk, or click on the Mount Disk button.

Select the virtual machine disk format – VMWare Workstation/vSphere ESXi (*.vmdk).

Choose the folder containing the files of the recovered virtual machine.

Select virtual machine disks and snapshots if necessary.

All selected disks and snapshots will be displayed in the program’s window.

Choose the one you need and perform the same sequence of actions for data recovery as you did to extract the virtual machine files.

Exit mobile version