Rename a Standard Port Group on all hosts in a cluster

Well, I recently decided to rename a bunch of my Standard Port Groups, since they did no longer reflect the network they were providing. Since I’m a lazy bastard (well lazy as in click lazy), I wrote this little PowerCLI script:

This script basically takes a vCenter instance and a single cluster, then creates a new Port Group on each host, after which it reconfigures all VMs possessing a virtual NIC with that Port Group and then deletes the old Port Group.

One thought to “Rename a Standard Port Group on all hosts in a cluster”

Leave a Reply to Bastiaan Cancel reply

Your email address will not be published. Required fields are marked *

I accept that my given data and my IP address is sent to a server in the USA only for the purpose of spam prevention through the Akismet program.More information on Akismet and GDPR.

This site uses Akismet to reduce spam. Learn how your comment data is processed.