I need to eager zero a Virtual Disk while building a VM. I found the function eagerZeroVirtualDisk_Task() under VcVirtualDiskManager, which takes in 2 params:
name - (string) The name of the disk, either a datastore path or a URL referring to the virtual disk that should be inflated.
datacenter - (VcDatacenter) If name is a datastore path, the datacenter for that datastore path. Not needed when invoked directly on ESX. If not specified on a call to VirtualCenter, name must be a URL.
How do I get the correct datastore path given the virtual disk? I intend to iterate through the devices in the VM to get the disks.
Thanks!