Attempting to set CPU|MemoryGuaranteedPercent to unlimited or 0 Ive tried $null also
This is what I get when I try
PS /home/ted/repos/provisioning/bin/vorg> $vdc
Name Enabled CpuUsedGHz MemoryUsedGB StorageUsedGB AllocationModel
---- ------- ---------- ------------ ------------- ---------------
Askew909-01 True 0.00 0.000 0.000 PayAsYouGo
PS /home/ted/repos/provisioning/bin/vorg> $vdc.MemoryGuaranteedPercent
1
PS /home/ted/repos/provisioning/bin/vorg> Get-Org -Name Askew909-01 | Set-OrgVdc -MemoryGuaranteedPercent 0
Set-OrgVdc : Cannot validate argument on parameter 'MemoryGuaranteedPercent'. A positive value is expected. At line:1 char:65
+ Get-Org -Name Askew909-01 | Set-OrgVdc -MemoryGuaranteedPercent 0
+ ~
+ CategoryInfo : InvalidData: (:) [Set-OrgVdc], ParameterBindingValidationException
+ FullyQualifiedErrorId : ParameterArgumentValidationError,VMware.VimAutomation.Cloud.Commands.Cmdlets.SetOrgVdc
PowerCli version is
PowerCLI Version
----------------
VMware PowerCLI 11.3.0 build 13990089
---------------
Component Versions
---------------
VMware Cis Core PowerCLI Component PowerCLI Component 11.3 build 13964830
VMware VimAutomation VICore Commands PowerCLI Component PowerCLI Component 11.3 build 13964826
VMware VimAutomation Vds Commands PowerCLI Component PowerCLI Component 11.2 build 12483615
VMware VimAutomation Cloud PowerCLI Component PowerCLI Component 11.0 build 10379994
Per the docs both the CPU and mem guaranteed: This parameter accepts values in the range of 0 to 100. Is there something Im doing wrong?
Thanks in advance
Ted
If your VDC is using the Pay As You Go or the Allocation Pool model, then this looks like at least a 'flaw' in the documentation.
Seems that the range 0-100 does not include the endpoint 0.
For mathematicians, 0 is neither positive nor negative.
So the error message is correct in stating that it wants a positive value.
I assume that all other values from 1 to 100 don't generate an error?
You could open a SR to make sure that there is indeed a flaw in the documentation.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Thanks for the reply.
You are correct I can set this from 1 - 100 w/o error, but I can also set it in the web UI to zero (0) and then Get-Org -Name blah | fl and it shows as zero (0).
I will open an SR.
Is it already solved? Having the same issue
The issue still not resolved at 2023-01.
vCD GUI allows to change CpuGuaranteedPercent into 0%.
PowerCLI VMware.VimAutomation.Cloud throws error:
Set-OrgVdc: Cannot validate argument on parameter 'CpuGuaranteedPercent'. A positive value is expected.
$null or empty string is not accepted.
PS C:\> Get-Module VmWare.PowerCLI | Select Version
Version
-------
13.0.0.20829139
PS C:\> Get-Module VMware.VimAutomation.Cloud | select Version
Version
-------
13.0.0.20809912