Creating a custom attribute with a number of shares per VM on each resource pool

Creating your base script to set the number of shares per resource pool is the first step to fully automating a process to update your share values in order to keep up with the changes and movements in the vSphere environment. Many vSphere environments can have multiple clusters and many more resource pools than just a Development, Test, and Production pool. For example, your environment can have a pool for mission critical systems and one for database systems.

If you have a complex environment, one method to automate the share value assignment is to define a number of shares per VM on each resource pool. This will allow you to take the predefined number of shares ...

Get PowerCLI Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.