3 Replies Latest reply on May 20, 2019 7:43 AM by LucD

    New-VM -OSCustomizationSpec not applying cust spec.  Just creates vm and sits there?  Gui works fine.

    davidb1234 Novice

      I have a new 6.7 deployment I am working with.  I installed powerCLI 6.5 and I created a template and an OS Customization Spec.  I am trying to deploy a VM from template and apply the customization spec.  This works fine from the GUI.  The deployed VM from template boots up and then runs sysprep, reboots, and applies the customization spec.


      However when done from PowerCLI the VM creates based upon template but the VM never reboots again and doesn't sysprep or apply customization spec. There are no errors.


      Any ideas?

      $VMTemplate = Get-Template -Name 'Win10Ent1809'

      $OSSpecs = Get-OSCustomizationSpec -Name 'Windows10Ent'

      New-VM -Name 'db-test-ent' -Template $VMTemplate -OSCustomizationSpec $OSSpec –VMHost 'nbfesxi01.mosherco.biz' -Datastore 'PURE_VMFS_1'