“unspecified path” couldn’t power on the machine”

Some old memories, Written on 03-08-2011

Today, I have come across a problem in powering a VM hosted at XXX and would like to share the solution. VM1 was unexpectedly shutdown, was not getting powered on and was popping up an error of “unspecified path” couldn’t power on the machine”.

Log analysis:

When checked the log file found this:

20:00:29.165: vmx| DISKLIB-CHAIN : “VM1.vmdk” : failed to open (The system cannot find the file specified).

Jun 25 20:00:29.165: vmx| DISKLIB-LIB   : Failed to open ‘VM1.vmdk’ with flags 0xa (The system cannot find the file specified).

Jun 25 20:00:29.166: vmx| Msg_Post: Error

Jun 25 20:00:29.166: vmx| [msg.disk.fileNotFound] VMware ESX cannot find the virtual disk “VM1.vmdk”. Please verify the path is valid and try again.

Jun 25 20:00:29.166: vmx| [msg.disk.noBackEnd] Cannot open the disk ‘VM1.vmdk’ or one of the snapshot disks it depends on.

Jun 25 20:00:29.166: vmx| [msg.disk.configureDiskError] Reason: The system cannot find the file specified

ESX host analysis:

when checked inside the ESX host through the command,

[root@VM123 VM1_1]# ls -ltr *.vmdk

-rw——- 1 root root 64424509440 Jun 25 19:39 VM1-flat.vmdk

found that the header file is missing. In this case we cant power on the vm because it will not have the information where is the flat.vmdk file located. So, I had to recreate a header /descriptor file for the virtual machine.

Steps for re creating header files:

1. Go to the data store where the problematic vm locating,

[root@VM1 SAN1]# cd /vmfs/volumes/SAN1/VM1_1

2. Check for the vmdk file and here you would not see any .vmdk header files, only vmdk file. Also,we must care about the file size which is 64424509440 for the flat.vmdk file.

[root@VM123 VM1_1]# ls -ltr *.vmdk

-rw——- 1 root root 64424509440 Jun 25 19:39 VM1-flat.vmdk

3. Find out the scsi controller used for the problematic vm earlier.

[root@VM123 VM1]# less *.vmx | grep -i Virtualdev

ddb.virtualHWVersion = “7”

ddb.longContentID = “02a25e06a0facb3cacc188b1f22dd778”

ddb.uuid = “60 00 C2 9c 6c c8 d7 00-04 02 73 49 0b ad 3b 71

ddb.geometry.cylinders = “7832”

ddb.geometry.heads = “255”

ddb.geometry.sectors = “63”

ddb.adapterType = “lsilogic”

4. Now we can use the vmkfstool for creating a disk of same size like before for the vm,

vmkfstools -c 64424509440 -a lsilogic -d thin tempVM1.vmdk

5. ls -ltr will provide the files details,

[root@VM123 VM1]# ls -ltr *.vmdk

-rw——- 1 root root 64424509440 Jun 25 20:29 tempVM1-flat.vmdk

-rw——- 1 root root         478 Jun 25 20:52 tempVM1.vmdk         ———– this is the descriptor file and we are creating this again which is a pointer to vmdk file.

-rw——- 1 root root 64424509440 Jun 25 23:10 VM1-flat.vmdk

6. Now to rename the vmdk file with the previous name,

[root@VM123 VM1]# mv tempVM1.vmdk VM1.vmdk

7. Now to edit the descriptor file,

[root@VM123 VM1]# vi VM1.vmdk

# Disk DescriptorFile

version=1

encoding=”UTF-8

CID=72c0250d

parentCID=ffffffff

createType=”vmfs”

# Extent description

RW 125829120 VMFS “VM1-flat.vmdk”   rename this to the original flat.vmdk file.

# The Disk Data Base

#DDB

ddb.toolsVersion = “8195”

ddb.adapterType = “lsilogic”

ddb.geometry.sectors = “63”

ddb.geometry.heads = “255”

ddb.geometry.cylinders = “7832”

ddb.uuid = “60 00 C2 9c 6c c8 d7 00-04 02 73 49 0b ad 3b 71”

ddb.longContentID = “e9ce77e0f6a3494c9bede9f872c0250d”

ddb.virtualHWVersion = “7”

ddb.thinProvisioned = “1”      and if the disk created earlier is not thin provisioned then take this like out of the file and save it.

8. Once this is done, we can power on the VM successfully.

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s