Κοινή χρήση μέσω


az azurestackhci virtualharddisk

Note

This reference is part of the azurestackhci extension for the Azure CLI (version 2.15.0 or higher). The extension will automatically install the first time you run an az azurestackhci virtualharddisk command. Learn more about extensions.

Command group 'azurestackhci' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Manage virtualharddisk with azurestackhci.

Commands

Name Description Type Status
az azurestackhci virtualharddisk create

Create a virtual hard disk.

Extension Experimental
az azurestackhci virtualharddisk delete

Delete a virtual hard disk.

Extension Experimental
az azurestackhci virtualharddisk list

List all virtual hard disks.

Extension Experimental
az azurestackhci virtualharddisk show

Get the details of a virtual hard disk.

Extension Experimental
az azurestackhci virtualharddisk update

Update a virtual hard disk.

Extension Experimental

az azurestackhci virtualharddisk create

Experimental

Command group 'azurestackhci' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Create a virtual hard disk.

az azurestackhci virtualharddisk create --name
                                        --resource-group
                                        [--block-size-bytes]
                                        [--disk-file-format]
                                        [--disk-size-bytes]
                                        [--disk-size-gb]
                                        [--dynamic {false, true}]
                                        [--extended-location]
                                        [--location]
                                        [--logical-sector-bytes]
                                        [--physical-sector-bytes]
                                        [--storagepath-id]
                                        [--tags]

Examples

PutVirtualHardDisk

az azurestackhci virtualharddisk create --resource-group "test-rg" --extended-location name="/subscriptions/a95612cb-f1fa-4daa-a4fd-272844fa512c/resourceGroups/dogfoodarc/providers/Microsoft.ExtendedLocation/customLocations/dogfood-location" type="CustomLocation" --location "West US2" --disk-size-bytes 32 --name "test-vhd" --storagepath-id "/subscriptions/a95612cb-f1fa-4daa-a4fd-272844fa512c/resourceGroups/dogfoodarc/providers/Microsoft.AzureStackHCI/storagecontainers/test-storagepath"

Required Parameters

--name

Name of the virtual hard disk.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Optional Parameters

--block-size-bytes

Block size.

--disk-file-format

Disk file format of the virtual hard disk - vhd or vhdx.

Usage: --disk-file-format "vhd".

--disk-size-bytes
Deprecated

Option '--disk-size-bytes' has been deprecated and will be removed in a future release. Use '--disk-size-gb' instead.

Deprecated. Please use --disk-size-gb instead. Size of the disk in GB.

--disk-size-gb

Size of the disk in GB.

--dynamic

Boolean for enabling dynamic sizing on the virtual hard disk. Allowed values: false, true.

Accepted values: false, true
--extended-location

Usage: --extended-location type=XX name=XX

type: The extended location type. name: The extended location name.

--location -l

Location. Values from: az account list-locations. You can configure the default location using az configure --defaults location=<location>.

--logical-sector-bytes

Logical Sector.

--physical-sector-bytes

Physical Sector.

--storagepath-id

Azure ID of the Storage Path which is used to store the VHD.

--tags

Space-separated tags: key[=value] [key[=value] ...]. Use "" to clear existing tags.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az azurestackhci virtualharddisk delete

Experimental

Command group 'azurestackhci' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Delete a virtual hard disk.

az azurestackhci virtualharddisk delete [--ids]
                                        [--name]
                                        [--resource-group]
                                        [--subscription]
                                        [--yes]

Examples

DeleteVirtualHardDisk

az azurestackhci virtualharddisk delete --resource-group "test-rg" --name "test-vhd"

Optional Parameters

--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

--name

Name of the virtual hard disk.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--yes -y

Do not prompt for confirmation.

Default value: False
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az azurestackhci virtualharddisk list

Experimental

Command group 'azurestackhci' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

List all virtual hard disks.

az azurestackhci virtualharddisk list [--resource-group]

Examples

ListVirtualHardDiskByResourceGroup

az azurestackhci virtualharddisk list --resource-group "test-rg"

ListVirtualHardDiskByResourceGroup

az azurestackhci virtualharddisk list

Optional Parameters

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az azurestackhci virtualharddisk show

Experimental

Command group 'azurestackhci' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Get the details of a virtual hard disk.

az azurestackhci virtualharddisk show [--ids]
                                      [--name]
                                      [--resource-group]
                                      [--subscription]

Examples

GetVirtualHardDisk

az azurestackhci virtualharddisk show --resource-group "test-rg" --name "test-vhd"

Optional Parameters

--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

--name

Name of the virtual hard disk.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az azurestackhci virtualharddisk update

Experimental

Command group 'azurestackhci' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Update a virtual hard disk.

az azurestackhci virtualharddisk update [--ids]
                                        [--name]
                                        [--resource-group]
                                        [--subscription]
                                        [--tags]

Examples

UpdateVirtualHardDisk

az azurestackhci virtualharddisk update --resource-group "test-rg" --tags additionalProperties="sample" --name "test-vhd"

Optional Parameters

--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

--name

Name of the virtual hard disk.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--tags

Space-separated tags: key[=value] [key[=value] ...]. Use "" to clear existing tags.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.