Pcornel
Automation · VMware Automation

VM Provisioning

Cheat sheet · https://pcornel.dk/topic.php?topic=5735

Back to the Topic

Answer

VMware VM provisioning deploys VMs from templates with New-VM -Template, OS customization specs, CPU, memory, disk and network settings, via PowerCLI, Terraform or Ansible.

Remember

  • New-VM -Template deploys from templates.
  • Customization specs set name and network.
  • Choose host and datastore.

First checks

  • New-VM -Name <n> -Template <tpl> -VMHost <h> -Datastore <ds> -OSCustomizationSpec <spec> — PowerCLI
  • govc vm.clone -vm <tpl> -on=false <n> — govc
  • terraform plan (vsphere_virtual_machine) — IaC

Commands

Get-VM -Name <vm> | Select-Object Name,PowerState,VMHost,Datastore
Read-only/validation observation for VM existence, power state, host placement and datastore placement for the selected…

Verify in this order

template → clone → customise → power on → register

Where it usually breaks

Input/desired state → request accepted → job/task terminal status → target object read-back → effective runtime state → original workload → regression/rollback readiness.

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=5735

Confirmation

Confirm action

Continue?