Symptoms
Failed to create swap file " and " Failed to power on VM " are recorded in vmware.log :YYYY-MM-DDTHH:MM:SS.000Z In(05) vmx - [vob.swap.poweron.createfailure.status] Failed to create swap file '/vmfs/volumes/vsan:<UUID>/<UUID>/<VM-Name>.vswp' : Failure
YYYY-MM-DDTHH:MM:SS.000Z In(05) vmx - [msg.vmmonVMK.creatVMFailed] Could not power on virtual machine: Failure.
YYYY-MM-DDTHH:MM:SS.000Z In(05) vmx - [msg.monitorLoop.createVMFailed.vmk] Failed to power on VM.
swapobjd.log on the destination ESXi records "Bad parameter (0xbad0007)", causing the creation of the vSAN vswp object to fail.YYYY-MM-DDTHH:MM:SS.000Z Er(11) swapobjd[0000000]: 00000000: OBJLIB-VSANOBJ: VsanObjGetExtParams: Could not unmarshal extended attributes: Bad parameter (0xbad0007).
<snip>
YYYY-MM-DDTHH:MM:SS.000Z Er(11) swapobjd[0000000]: 00000000:SwapObjCreateFileInt:298: Failed to create object /vmfs/volumes/vsan:<UUID>/<UUID>/<VM-Name>.vswp (Invalid argument).
VMware vSAN 8.0
VMware vSphere ESXi 8.0
This is a known issue in vSAN.
Rerun the vMotion to migrate the VM.
This issue has been fixed in vSAN 9.0, and we are planning a release with the fix for vSAN 8.0.