0

How to retrieve datastores in VMWARE based on the cluster name using Pyvmomi. [vim.Storagepod] gives null result, so is there any other way to retrieve the datastores filtering on the datacluster name.

datastores = get_all_objs(content, vim.StoragePod) It returns a null object

Spurthi
  • 1
  • 1

1 Answers1

0

You're on the right track. You need to use:

    datastores = get_all_objs(content, [vim.StoragePod])
Justin
  • 490
  • 1
  • 3
  • 11
  • When i refer the cluster, its not datatstore cluster name. It is the site under the datacenter. Is it possible to retrieve the datastores based on site filter? – Spurthi Jun 26 '20 at 16:12
  • That's a different question. – Justin Jun 28 '20 at 02:18