looks like the datastore where the VMDK file resides is corrupt, probably due to disk hardware errors. The Guest OS probably has not yet allocated any of the bad sectors, so it hasn't noticed the corruption until now.
Try to copy the vmdk file from the ESXi console using dd with the switch conv=noerror (This should ignore read errors).
You can also try to back up the disk from within the Guest OS (using Windows Backup if it runs Windows, a CloneZilla boot disk, or other disk imaging software that is able to ignore read errors).
Thank you for the suggestion, I am unable to get the dd command to work properly, not sure if I am doing something wrong.
Anyhow it looks like I may need to image it somehow as the machine is a legacy freebsd OS so there is no local backup options that I am aware of. I'll try your suggestion of Clonezilla and see how that goes
This is caused by datastore when filesystem is formated with block size not recognized by vmware,
you can find the block size of your datastore by using fdisk
There is switch to DD where you can specify the block size of source datastore. use it to copy vmdk to a datastore recognized by vmware
This is the problem on your ESXI host where your VM is running on. To isolate issue, do vMotion to other host and retry one of those task on this machine.
I got this issue few days back when I was enabling HA on VCSA, cloning of VCSA VM was failing with same error as you mentioned, logged a case with VMware results no help. This host also gave other smaller errors for normal operations such increasing/decreasing resources which made me doubt on ESXI host itself. I vmotioned 2 VMs to another host then was able to clone successfully.
Try this if it works.
Did the dd command fail with an I/O error ?
In that case I would suggest to do the following:
go to the directory with putty and run the command
vmkfstools -p 0 name-flat.vmdk >> mapping.txt
attach the mapping.txt to your next reply
I will create a different dd-command then.
For me the dd says:
vmware # dd conv=noerror if=/vmfs/volumes/datastore2/Data/Data-flat.vmdk of=/vmfs/volumes/datastore4/Data/Data-flat.vmdk
dd: can't open '/vmfs/volumes/datastore2/Data/Data-flat.vmdk': Invalid argument
I verified that I could make a disk file of the same size as the source disk:
/vmfs/volumes/5b8d8777-8bfbb68c-56a0-a4badbfb2eac/Data_Copy # vmkfstools -c 80530636800 xx.vmdk
Create: 100% done.
/vmfs/volumes/5b8d8777-8bfbb68c-56a0-a4badbfb2eac/Data_Copy # ls -l
-rw------- 1 root root 8684 Sep 4 01:47 Data.nvram
-rw------- 1 root root 0 Sep 4 01:48 Data.vmsd
-rw------- 1 root root 3297 Sep 3 22:46 Data.vmx
-rw------- 1 root root 259 Sep 4 01:48 Data.vmxf
-rw------- 1 root root 80530636800 Sep 4 02:03 xx-flat.vmdk
-rw------- 1 root root 464 Sep 4 02:03 xx.vmdk
Here is the source. Note the error about the missing Data.vmdk. Perhaps that is my problem somehow?
/vmfs/volumes/52d85079-cc5e83dc-5f66-a4badbfb2eac/Data # ls -l
ls: ./Data.vmdk: No such file or directory
-rw-r--r-- 1 root root 27 Feb 12 2014 Data-9c51ad3b.hlog
-rw------- 1 root root 805306368000 Sep 3 00:07 Data-flat.vmdk
-rw------- 1 root root 8684 Sep 3 05:53 Data.nvram
-rw------- 1 root root 0 Jan 17 2014 Data.vmsd
-rwx--x--- 1 root root 3297 Sep 4 01:39 Data.vmx
-rw------- 1 root root 259 Sep 3 05:51 Data.vmxf
-rw-r--r-- 1 root root 162382 Sep 12 2017 vmware-12.log
-rw-r--r-- 1 root root 475869 Oct 3 2017 vmware-13.log
-rw-r--r-- 1 root root 8011602 Aug 31 10:10 vmware-14.log
-rw-r--r-- 1 root root 166094 Sep 3 05:53 vmware-15.log
-rw-r--r-- 1 root root 38959 Sep 3 05:53 vmware-16.log
-rw-r--r-- 1 root root 38909 Sep 3 22:39 vmware-17.log
-rw-r--r-- 1 root root 38911 Sep 4 01:40 vmware.log
/vmfs/volumes/5b8d8777-8bfbb68c-56a0-a4badbfb2eac/Data # ls
Data.vmsd Data.vmx Data.vmxf
/vmfs/volumes/5b8d8777-8bfbb68c-56a0-a4badbfb2eac/Data # ls -l
-rw------- 1 root root 0 Sep 4 01:46 Data.vmsd
-rw------- 1 root root 3297 Sep 4 01:46 Data.vmx
-rw------- 1 root root 259 Sep 4 01:46 Data.vmxf
Data.vmdk is missing.
That will not have any influence on a dd command against Data-flat.vmdk
When you cant dd the flat.vmdk you may have an I/O error in the flat.vmdk.
Call me via skype - I can handle that if necessary ....
Sorry for short answer. I am in a hurry ...
May i know how to fix this issue?