VMWare ESXi Unable to delete datastore

15 pts.
Tags:
VMware
VMware error messages
VMware ESXi
I have tried removing my VMDatastore1 in order to recreate it and increase the block size. I am getting the following message ' ERROR DURING THE CONFIGURATION OF HOST: DESTROYVMFSDATASTORE: CANT DELETE PARTITION 3 ON LUN vmhba2:0:0'. Is this some sort of registry from when it was first created? On the properties tab there is information under the Extent Device pane relating to Primary Partitions, any help would be very much appreciated.

Answer Wiki

Thanks. We'll let you know when a new response is added.

Is this local storage or shared storage? If it is shared storage make sure all hosts that have the datastore configured have it removed from their configuration. For both make sure all VMs are shutdown. If this is local storage then after you have the VMs shutdown (or deleted) try restarting the host to remove any disk locks and then remove the volume.

ESX 3.5.0 has a bug that will cause the delete of the datastore to fail. You can see the error if you look in /var/log/vmware/hostd-*.log and see something like:

<pre>Error : Error: The partition table on /vmfs/devices/disks/vml…. is inconsistent.

the most likely reason is that Linux detected the BIOS geometry for /vmfs/devices/disks/vml….incorrectly. GNU Parted suspects the real geometry should be 46208/64/32 (not 5890/255/63).</pre>

You can just directly reformat the datastore without deleting it and creating it.
<b>This will still DESTROY everything on the datastore:</b>

<pre>vmkfstools -C vmfs3 -b <i>blocksize</i> -S <i>datastore_name device</i></pre>

For example:

<pre>vmkfstools -C vmfs3 -b 2m -S storage1 /vmfs/devices/disks/vmhba1:0:0:3</pre>

Discuss This Question: 2  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Halsey
    Thanks for the tip DonLaw. I was having trouble deleting a datastore despite removing all the VMs and rebooting. Simply reformatting was all I needed to do, so the command you gave was a huge help.
    10 pointsBadges:
    report
  • AnangE56
    may be you can try to rescan VMFS in each ESX >> select inventory in host & cluster view >> select esx and go to the configuration >> in storage adapters try to re scan nmba1, vmba2 and vmba0 may be it help u.. tq,
    10 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following