SANtricity 11.8 Commands ( CA08871-194 ~ 196 )

Format rules for CLI commands in Windows PowerShell

The Windows PowerShell is an interactive and scripting shell that provides access to command-line tools. The Windows PowerShell improves upon the Windows Command Prompt with a more robust set of commands and scripting capability. You can run all of the CLI and script commands in the Windows PowerShell; however, the Windows PowerShell has some unique formatting requirements. The requirements are these:

  • Begin all SMcli commands with a period and a forward slash (./)

  • SMcli wrapper must be identified as an executable command with the .exe extension (SMcli.exe)

  • Enclose the script command in single quotation marks (' ')

  • Double quotation marks that are part of a name, file path, or value must have a backslash before each double quotation mark character (\")

The following is an example of a CLI command to create a storage system name in the Windows PowerShell. Note the use of the single quotation marks as delimiters for the script command and the backslash double quotation marks around the storage system name, identified as userLabel in the command syntax.

PS C:\...\StorageManager\client> ./SMcli.exe 123.45.67.88 123.45.67.89
-c ’set storageArray userLabel=\"Engineering\";’

The following is an example of a CLI command to enable a premium feature in the Windows PowerShell. Note the use of the backslash double quotation marks before the file path to the premium feature key.

PS C:\...\StorageManager\client> ./SMcli.exe 123.45.67.88 123.45.67.89
-c ’enable storageArray feature file=\"C:\licenseKey.bin\";’

In the previous examples both upper case letters and lower case letters are used. This use is to help make clear how the commands are formatted. The Windows PowerShell is, however, not case sensitive and does not require the use specific cases.

Top of Page