vCO workflow – change vCPU count

Recently I started to develop\build my own vCenter Orchestrator workflows. I must say it is not as hard as I thought but it is not easy either. My workflows are quite simple however within a time I will develop them to be more “smart” Laughing.

Change vCPU count on VM (hot add)

[box type=”warning”] Note: before you start below workflow, make sure that VM has enabled hot add features and guest OS supports hot add CPU[/box]

First workflow is to increase vCPU count, by hot add features, on virtual machine.

vCO - add vCPU

vCO – hot add vCPU

How it works:

  • Step 1
    • As an input workflow require virtual machine name – you can choose from vCenter inventory tree
  • Step 2
    • new vCPU count – you can choose from predefined list
  • executes action
choose CPU count

choose CPU count

Decrease number of vCPU

Second workflow can either increase or decrease vCPU count on powered off VM only. Why only on powered of VM ? Because vCPU hot remove is not supported by Gues OS I know of and I’m not good enough to verify if user try to increase or decrease number of vCPU’s.

How it works:

  • Step 1.
    • As an input workflow require virtual machine name – you can choose from vCenter inventory tree
  • Step 2
    • new vCPU count – you can choose from predefined list
  • verifies if VM is powered on:
    • YES – power VM down, wait 2 minutes and if VM is still up – perform power off action, change CPU, wait for task to complete, Start VM
    • NO – change CPU count, wait for task to complete, start VM

[box type=”warning”] NOTE: increase and decrease vCPU count is performed on Powered Of VM[/box]

vCO - remove vCPU

vCO – remove vCPU

[box type=”download”] Download both vCO workflows[/box]

Artur Krzywdzinski

Artur is Consulting Architect at Nutanix. He has been using, designing and deploying VMware based solutions since 2005 and Microsoft since 2012. He specialize in designing and implementing private and hybrid cloud solution based on VMware and Microsoft software stacks, datacenter migrations and transformation, disaster avoidance. Artur has been in IT industry since 1999 and consulting since 2008. Artur holds VMware Certified Design Expert certification (VCDX #077).