ESXi datastore recovery problem

I was running esxi on a flash drive (why? because it sounded like a cool idea) and the flash drive got bumped and damaged and I had to reinstall esxi on a new flash drive and booting up on it, it sees the two datastores on the sata hard drives on the computer but it doesn't see any of the vm's that I know are there.

The computer didn't get damaged, just the original flash drive.

I click on browse datastore and it searches for a long time with a lot of linux-looking dots ...............................................................................................................................................................................................................

And then it finds nothing.

The vm's are there.  I can tell by the free space reported.

So how do I get them back.

Any ideas?

Thanks.
gateguardAsked:
Who is Participating?
 
Andrew Hancock (VMware vExpert / EE MVE^2)Connect With a Mentor VMware and Virtualization ConsultantCommented:
1. Connect to the server via SSH or login at the console and check /vmfs/volumes for any folders or files.

When you re-installed, it's possible it could have re-formatted the current vmfs partitions.

otherwise, I can recommend the use of VMFS Recovery, which can recovery virtual machine (vmdk) disks from VMFS partitions.

http://www.diskinternals.com/vmfs-recovery/
0
 
Paul SolovyovskySenior IT AdvisorCommented:
browse to the datastore-> VM Folders - VMX file.  Right click on VMX file and click "register Virtual Machine"

That should do it.
0
 
DavidConnect With a Mentor PresidentCommented:
Nothing wrong with doing that, booting to flash is a reasonable and common thing to do.  (But next time use industrial flash that you just plug into the motherboard directly or use an extension cable so you can tape the USB to the outside of the system.

Warning: This is a UNIX 101 response, not specific to vmware.  This is how one deals with a munged file system for most *NIX. [No indication from your Q if this is file system that got initialized, munged, or a configuration change is in order]

Create another bootable USB stick, but use a linux distribution, not esxi.  boot to the new stick.  Then do a man fsck.    The man pages will give you an option to do a file system check that is read-only, I don't remember the option for linux, but -m works with other UNIX flavors, as well as -v for verbose.

Do the fsck and see if it finds problems or all is good.  If the report looks "reasonable" then cross fingers and run fsck w/o the read-only option.  (The point of this is that you can't run fsck from a mounted file system, or it will really mess you up).

There may be more elegant ways, this is A way.  P.S.  Best practice is to use dd and take an image dump of the munged up USB drive and save that dump to the network or something just in case.
0
 
Paul SolovyovskyConnect With a Mentor Senior IT AdvisorCommented:
I would also check if you have internal USB or SD slot (SD preferred), this would be a better choice
0
 
gateguardAuthor Commented:
Thanks.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.