serial-portvmwarevmware-claritypyvmomi

Pyvmomi get CRUD operations for Portgroup


I want to write a script in Python & Django, where I will do CRUD operations for Port-group. I am working on VM Sphere / VM-Ware. But after searching a lot I got only a single repository for reference - https://github.com/vmware/pyvmomi-community-samples/tree/master/samples

PyVmomi library.

I am not able to write script for CRUD operations of Portgroup. Please also explain that are Port group under Central server access or under proxy access or under VM access. Please discuss in details.


Solution

  • Three of those operations already exist as part of the pyvmomi community samples repo, which you linked:

    Hopefully those three samples can help you get on your way to creating the script you require.

    Access-wise, portgroups are a child object of the ESXi host (or HostSystem) within the API. You can either authenticate directly to the managing vCenter Server or to the ESXi Host itself to manage portgroups.