Quantcast
Channel: VMware Communities : Discussion List - All Communities
Viewing all articles
Browse latest Browse all 193198

Need pointed to info on powercli, reconfigvm error message

$
0
0

Greetings...

 

I am fairly new at powershell/powercli but found sample code to change a vm configuration parameter found in the gui under options > advanced - general.  Specifically, I want to change disk.enableuuid to false from true.  The error I get is as follows:

 

Exception calling "ReconfigVM_Task" with "1" argument(s): "Current license or
ESXi version prohibits execution of the requested operation."
At C:\Users\dclowers\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.p
s1:52 char:7
+       $Task = ($singlevm.ExtensionData).ReconfigVM_Task($vmConfigSpec)
+       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : VimException

 

This is a new install of esxi 5.1, no vcenter.  Is this a function no longer allowed and/or is there another way to do this?  I've tried numerous sample scripts similar to the following and all of them bomb on the vm.reconfigvm line:

 

$key = "Key to set"
$value = "Value to set"
get-vm | foreach {
  $vm = Get-View $_.Id
  $vmConfigSpec = New-Object VMware.Vim.VirtualMachineConfigSpec
  $vmConfigSpec.extraconfig += New-Object VMware.Vim.optionvalue
  $vmConfigSpec.extraconfig[0].Key=$key
  $vmConfigSpec.extraconfig[0].Value=$value
  $vm.ReconfigVM($vmConfigSpec)
}

 

Thanks in advance for any guidance!

 

Don


Viewing all articles
Browse latest Browse all 193198

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>