Export (0) Print
Expand All
Expand Minimize

Set-SCStorageVolume

Updated: April 29, 2014

Applies To: System Center 2012 R2 Virtual Machine Manager

Set-SCStorageVolume

Modifies the setting for a volume on a host that enables VMM to evaluate that volume as available storage during the virtual machine placement process.

Syntax

Parameter Set: Default
Set-SCStorageVolume [-StorageVolume] <StorageVolume> -AvailableForPlacement <Boolean> [-JobVariable <String> ] [-PROTipID <Guid> ] [-RunAsynchronously] [ <CommonParameters>]




Detailed Description

The Set-SCStorageVolume cmdlet modifies the setting that determines whether Virtual Machine Manager (VMM) will evaluate a specific volume on a host server as available storage during the virtual machine placement process.

During the placement process, VMM evaluates managed hosts, including the volumes on those managed hosts, when calculating a recommendation for the best location on which to deploy a virtual machine. If you specify that a volume on the host will not be included when VMM performs its automatic placement calculation, you can still choose to manually deploy a virtual machine on that volume.

Parameters

-AvailableForPlacement<Boolean>

Indicates whether the VMM placement process will consider this host or this volume on a host to be eligible as a possible location on which to deploy virtual machines. If this parameter is set to $False, you can choose to deploy virtual machines on this host or volume anyway. The default value is $True. This parameter does not apply to VMware ESX hosts.

When this parameter is used with network adapters, if set to $False, then placement will not consider the logical networks configured on this network adapter to determine if the host is suitable for connecting a virtual machine.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-JobVariable<String>

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


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-PROTipID<Guid>

Specifies the ID of the PRO tip that triggered this action. This allows for auditing of PRO tips.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RunAsynchronously

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


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-StorageVolume<StorageVolume>

Specifies a storage volume object on a specific virtual machine host.


Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters.

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

  • StorageVolume

Examples

Example 1: Make a volume on a host available for placement

The first command gets the host object named VMHost01, and then stores the object in the $VMHost variable.

The second command gets the storage volume object for the host stored in $VMHost, and then stores the object in the $StorageVol variable. This example assumes that VMHost01 has only one volume.

The last command makes the first volume object on VMHost01 available for placement. Setting the parameter AvailableForPlacement to $True enables the VMM placement process to evaluate this volume on VMHost01 as a possible candidate to host virtual machines.


PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost01.Contoso.com"
PS C:\> $StorageVol = Get-SCStorageVolume -VMHost $VMHost
PS C:\> Set-SCStorageVolume -StorageVolume $StorageVol[0] -AvailableForPlacement $True

Example 2: Make a second volume on a host available for placement

The first command gets the host object named VMHost02, and then stores the object in the $VMHost variable.

The second command gets all storage volume objects VMHost02, and then stores the objects in the object array named $StorageVols. This example assumes that VMHost02 has at least two volumes.

The last command makes the second volume stored in the $StorageVols array available for placement.


PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost02.Contoso.com"
PS C:\> $StorageVols = Get-SCStorageVolume -VMHost $VMHost
PS C:\> Set-SCStorageVolume -StorageVolume $StorageVols[1] -AvailableForPlacement $True

Related topics

 
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft