0

How to exactly use the pyvmomi library to get the above mapping, I mean what data structures to use particularly. I suppose it should be done via data store.

def getdatastore(datastore):
try:
  summary = datastore.summary
  return summary.name
except Exception as error:
  print "Unable to access summary for datastore: ", datastore.name
  print error
  pass

tried with the above function but in vain

Amruthapv
  • 3
  • 5

1 Answers1

0

You said you want to map "from VM to Storage"

Do you mean vm.datastore ?

If not, can you explain your self better ? (I'm sorry I can't comment, dont have 50 rep)

Emanuel
  • 640
  • 1
  • 7
  • 25