Partager via


Set-SCCloudCapacity

Modifies the cloud capacity settings for a private cloud.

Syntax

FromValues

Set-SCCloudCapacity
    -CloudCapacity <CloudCapacity>
    [-CPUCount <UInt32>]
    [-UseCPUCountMaximum <Boolean>]
    [-MemoryMB <UInt32>]
    [-UseMemoryMBMaximum <Boolean>]
    [-StorageGB <UInt32>]
    [-UseStorageGBMaximum <Boolean>]
    [-CustomQuotaCount <UInt32>]
    [-UseCustomQuotaCountMaximum <Boolean>]
    [-VMCount <UInt32>]
    [-UseVMCountMaximum <Boolean>]
    [-VMMServer <ServerConnection>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

JobGroupParamSet

Set-SCCloudCapacity
    -JobGroup <Guid>
    [-CPUCount <UInt32>]
    [-UseCPUCountMaximum <Boolean>]
    [-MemoryMB <UInt32>]
    [-UseMemoryMBMaximum <Boolean>]
    [-StorageGB <UInt32>]
    [-UseStorageGBMaximum <Boolean>]
    [-CustomQuotaCount <UInt32>]
    [-UseCustomQuotaCountMaximum <Boolean>]
    [-VMCount <UInt32>]
    [-UseVMCountMaximum <Boolean>]
    [-VMMServer <ServerConnection>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

Description

The Set-SCCloudCapacity cmdlet modifies the cloud capacity settings for a private cloud in Virtual Machine Manager (VMM). You can update the following cloud capacity dimensions:

  • virtual machines
  • virtual CPUs
  • custom quota points
  • storage (GB)
  • memory (MB)

Alternatively, you can set any or all of the dimensions to use the maximum capacity.

Examples

Example 1: Change the cloud capacity properties of a specified cloud

PS C:\> $Cloud = Get-SCCloud -Name "Cloud01"
PS C:\> $CloudCapacity = Get-SCCloudCapacity -Cloud $Cloud
PS C:\> Set-SCCloudCapacity -CloudCapacity $CloudCapacity -VirtualCPUCountLimited $True -VirtualCPUCount 20

The first command gets the private cloud object named Cloud01 and stores the object in the $Cloud variable.

The second command gets the cloud capacity for the private cloud stored in $Cloud and stores it in the $CloudCapacity variable.

The last command indicates that there should be a limit placed on the virtual CPU count for the cloud capacity stored in $CloudCapacity, and changes the virtual CPU count capacity to 20.

Example 2: Change the cloud capacity properties of a specific private cloud using a job group

PS C:\> $Guid = [System.Guid]::NewGuid()
PS C:\> $Cloud = Get-SCCloud -Name "Cloud02"
PS C:\> $CloudCapacity = Get-SCCloudCapacity -Cloud $Cloud
PS C:\> Set-SCCloudCapacity -JobGroup $Guid -VirtualMachinesLimited $True -VirtualMachines 50 -VirtualCPUCountLimited $True -VirtualCPUCount 100 -StorageLimited $True -StorageGB 500
PS C:\> Set-SCCloud -JobGroup $Guid -Cloud $Cloud

The first command creates a new GUID and stores it in the $Guid variable. Subsequent commands that include this GUID are collected into a single job group.

The second command gets the private cloud object named Cloud02 and stores the object in the $Cloud variable.

The third command gets the cloud capacity object for the private cloud stored in $cloud and stores the object in the $CloudCapacity variable.

The fourth command sets a limit of 50 virtual machines, 100 virtual CPUs and 500 GB of storage on the cloud capacity. Using the JobGroup parameter specifies that this command will not run until just before the final command that includes the JobGroup with the same GUID.

The last command sets the capacity properties on the private cloud stored in $Cloud using the settings that were specified in the fourth command. This command uses the JobGroup parameter to run Set-SCCloudCapacity just before Set-SCCloud runs so that the settings will be assocated with the specified private cloud.

Parameters

-CloudCapacity

Specifies a cloud capacity object.

Parameter properties

Type:CloudCapacity
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

FromValues
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Parameter properties

Type:SwitchParameter
Default value:False
Supports wildcards:False
DontShow:False
Aliases:cf

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPUCount

Specifies the number of virtual CPUs for a user role quota or cloud capacity.

Parameter properties

Type:UInt32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CustomQuotaCount

Specifies the number of custom quota points for a user role quota or cloud capacity.

Parameter properties

Type:UInt32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-JobGroup

Specifies an identifier for a series of commands that will run as a set just before the final command that includes the same job group identifier runs.

Parameter properties

Type:Guid
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

JobGroupParamSet
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-JobVariable

Specifies that job progress is tracked and stored in the variable named by this parameter.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-MemoryMB

Specifies the amount of memory in megabytes (MB) for a user role quota or cloud capacity.

Parameter properties

Type:UInt32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-PROTipID

Specifies the ID of the Performance and Resource Optimization (PRO) tip that triggered this action. This allows for auditing of PRO tips.

Parameter properties

Type:Guid
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-RunAsynchronously

Indicates that the job runs asynchronously so that control returns to the command shell immediately.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-StorageGB

Specifies the amount of storage in gigabytes (GB) for a user role quota or cloud capacity. This storage amount does not include library storage.

Parameter properties

Type:UInt32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UseCPUCountMaximum

Indicates whether the maximum number of virtual CPUs is allowed for a user role or cloud capacity. When this parameter is used, no quota is enforced for the virtual CPU dimension.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UseCustomQuotaCountMaximum

Indicates whether the maximum number of custom quota points is allowed for a user role or cloud capacity. When this parameter is used, no quota is enforced for the custom quota dimension.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UseMemoryMBMaximum

Indicates whether the maximum amount of memory, in megabytes (MB), is allowed for a user role or cloud capacity. When this parameter is used, no quota is enforced for the memory dimension.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UseStorageGBMaximum

Indicates whether the maximum amount of storage, in gigabytes (GB), is allowed for a user role or cloud capacity. When this parameter is used, no quota is enforced for the storage dimension.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UseVMCountMaximum

Indicates whether the maximum number of virtual machines is allowed for a user role or cloud capacity. When this parameter is used, no quota is enforced for the virtual machine dimension.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VMCount

Specifies the number of virtual machines for a user role quota or cloud capacity.

Parameter properties

Type:UInt32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VMMServer

Specifies a VMM server object.

Parameter properties

Type:ServerConnection
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Parameter properties

Type:SwitchParameter
Default value:False
Supports wildcards:False
DontShow:False
Aliases:wi

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.