Import-SpbmStoragePolicy

This cmdlet imports a storage policy from a file. The file path must be accessible from the VMware PowerCLI client side.

Syntax

[-Name]  <String>
-FilePath  <String>
[-Description  <String>]
[-Server  <VIServer[]>]
[CommonParameters]

Parameters

Required Parameter Name Type Position Features Description
required
Name
String 1 Specifies a name of the imported storage policy. The maximum length of the name is 80 characters.
required
FilePath
String named Specifies the path to the file, from which you want to import a storage policy. If relative, it is relative to the current PS provider path.
optional
Description
String named Specifies a description for the imported storage policy.
optional
Server
VIServer[] named
  • wildcards
  • 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 Connect-VIServer.

    Output

    VMware.VimAutomation.Storage.Types.V1.Spbm.SpbmStoragePolicy

    Examples


    Example 1

    Import-SpbmStoragePolicy -Name "MyPolicy" -Description "PolicyDescription" -FilePath C:\policy.xml

    Imports a storage policy with name "MyPolicy" and description "PolicyDescription" from the policy.xml file to a server. A new storage policy is created on the server.

    Related Commands

    Feedback

    Was this page helpful?