Hello Pradeep,
thanks for reply, with REST API I know but as I wrote our Dev Team is using the Python SDK and they want to get a VM list via the SDK.
So and there I did not found any modul etc…
Maybe anyone already did it with Python SDK…
Thx & BR
Marcel
Hi @Marcel Geisen
Let me check and update details at the earliest.
@Marcel Geisen
Kindly refer below document and module.
https://commvault.github.io/cvpysdk/cvpysdk/client.html#cvpysdk.client.Clients.add_exchange_client
_get_virtualization_clients() -- gets all the virtualization clients associated with the commcell
@Pradeep thanks for checking again, with get_virtualization_clients you only get the hypervisor objects and not the virtual machines… this we already tested before, because we thought the same as you.
So till now I could not find an easy way to get with Python SDK.
Thx
Hi Marcel,
commcell = cvpysdk.commcell.Commcell('<CS Name>','<UserName>','<Password>',
force_https=True,verify_ssl=False)
client = cvpysdk.clients.vmclient.VMClient(commcell,client_name='<Virtualization Client Name here>')
agent = client.agents.get('Virtual Server')
backupsets = agent.backupsets.get('defaultBackupSet')
Content = cvpysdk.subclients.virtualserver.vmware.VMWareVirtualServerSubclient(backupset_object=backupsets,subclient_name='<Subclient Name>')
print(Content.preview_content())
please check if it works