VirtualTman
Contributor
Contributor

cannot add virtual disk to vm after copying via putty session to new LUN

I detached a large 1TB vmdk from a vm, then migrated the vm to a new LUN. After that, I copied the large vmdk using cp command via putty from the old location to new (both 8mb block size luns)

I had to call the vmdk a different name in target location as there was already one by that name.

Why can I not add the vmdk to the server afterwards? Is it perhaps due to a file lock? If so, how would i remove the lock? I get the following error when trying to add the copied file and i did notice that while adding it, it was reporting an incorrect size in VI Client (yet correct size on file system and copy was completed successfully)

Uneditable device: Internal problem: The system information reported by the host for the 'VirtualDisk' is inconsustent. The device cannot currently be edited

On clicking ok on the error i get:

Object reference not set to an instance of an object

Any help would be most appreciated! Thank-you!

0 Kudos
3 Replies
VirtualTman
Contributor
Contributor

Update: I followed this procedure to edit the vmdk to replace a legacy adaptor type with 'lsilogic'

I could then add the file but on turning server on I get: "unable to access a file since it is locked"

Any ideas, how do i remove a file lock on a vmdk? Would that solve the issue?

0 Kudos
AliMadrid
Contributor
Contributor

Hi,

You prob have stale lock file, that's left there by a VM. Created in the same dir as .vmdk

You can try to delete if manually, it'll be *.WRITELOCK.

Regards

Ali

--

Senior Consultant

ABYM Consulting

Senior Consultant ABYM Consulting http://www.abym.es
0 Kudos
VirtualTman
Contributor
Contributor

Hi there thanks for this although it doesn't seem to be this as I cannot see any of those files there.

I am busy working on a workaround as I cannot add this drive. I have rebooted every esx server that the vm was kown to be running on and still no joy. Strange one.

0 Kudos