New-WMNamespaceStoragePolicy
This cmdlet creates a storage claim for a workload namespace using the specified configuration. The storage claim is expressed as a storage policy and parameters of the claim. The cmdlet requires a connection to vCenter Server using the Connect-VIServer cmdlet.
Syntax
-StoragePolicy <SpbmStoragePolicy>
[-LimitMiB <Int64>]
[-Server <VIServer[]>]
[CommonParameters]
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required |
|
WMNamespace | named |
|
Specifies the workload namespace that you want to use the storage. | required |
|
SpbmStoragePolicy | named |
|
Specifies the storage policy that you want to apply to the storage used by the specified workload namespace. | optional |
|
Int64 | named |
|
Specifies the limit on the storage used by workloads running in the specified workload namespace. | optional |
|
VIServer[] | named |
|
Specifies the vCenter Server systems on which you want to run the cmdlet. If no value is provided or $null value is passed to this parameter, the command runs on the default servers. For more information about default servers, see the description of the Connect-VIServer cmdlet. |
Output
VMware.VimAutomation.WorkloadManagement.Types.V1.WMNamespaceStoragePolicy
Examples
Example 1
Creates a storage claim for the workload namespace "MyNamespace". The storage policy "MyStoragePolicy" would be applied to the storage used by workloads running in this workload namespace. There would be no limit on the storage used by those workloads.
Example 2
Creates a storage claim for the workload namespace "MyNamespace". The storage policy "MyStoragePolicy" would be applied to the storage used by workloads running in this workload namespace. There would a limit of 2048 MiB on the storage used by those workloads.
Related Commands
WMNamespace
WMNamespaceLimits
WMNamespaceNetworkSpec
WMNamespacePermission