vmware / pyvmomi

VMware vSphere API Python Bindings
Apache License 2.0
2.21k stars 766 forks source link

Mount datastore to additional ESX hosts #745

Open shyamachilles opened 5 years ago

shyamachilles commented 5 years ago

Could someone please let me know how to mount a VVOL datastore to additional ESXi hosts apart from the one with which it was created.

yoni386 commented 7 months ago

CreateVvolDatastore is what you're looking for.

DuplicateName should be thrown if it exists in the same space. by space, it refers to esx. If esx, is not mounted to vol then it "mounts it"

https://vdc-repo.vmware.com/vmwb-repository/dcr-public/fa5d1ee7-fad5-4ebf-b150-bdcef1d38d35/a5e46da1-9b96-4f0c-a1d0-7b8f3ebfd4f5/doc/vim.host.DatastoreSystem.html#createVvolDatastore

CreateVvolDatastore(createVvolDatastore)