Share via


az vmss extension

Manage extensions on a VM scale set.

Commands

Name Description Type Status
az vmss extension delete

Delete an extension from a VMSS.

Core GA
az vmss extension image

Find the available VM extensions for a subscription and region.

Core GA
az vmss extension image list

List the information on available extensions.

Core GA
az vmss extension image list-names

List virtual machine extension image types.

Core GA
az vmss extension image list-versions

List virtual machine extension image versions.

Core GA
az vmss extension image show

Get a virtual machine extension image.

Core GA
az vmss extension list

List extensions associated with a VMSS.

Core GA
az vmss extension set

Add an extension to a VMSS or update an existing extension.

Core GA
az vmss extension show

Show details on a VMSS extension.

Core GA
az vmss extension upgrade

Upgrade all extensions for all VMSS instances to the latest version.

Core GA

az vmss extension delete

Delete an extension from a VMSS.

az vmss extension delete --name
                         --resource-group
                         --vmss-name
                         [--no-wait]

Examples

Delete an extension from a VMSS. (autogenerated)

az vmss extension delete --name MyExtension --resource-group MyResourceGroup --vmss-name MyVmss

Required Parameters

--name -n

Name of the extension.

--resource-group -g

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

--vmss-name

Scale set name. You can configure the default using az configure --defaults vmss=<name>.

Optional Parameters

--no-wait

Do not wait for the long-running operation to finish.

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 vmss extension list

List extensions associated with a VMSS.

az vmss extension list --resource-group
                       --vmss-name

Examples

List extensions associated with a VMSS. (autogenerated)

az vmss extension list --resource-group MyResourceGroup --vmss-name MyVmss

Required Parameters

--resource-group -g

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

--vmss-name

Scale set name. You can configure the default using az configure --defaults vmss=<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 vmss extension set

Add an extension to a VMSS or update an existing extension.

Get extension details from az vmss extension image list.

az vmss extension set --name
                      --publisher
                      --resource-group
                      --vmss-name
                      [--enable-auto-upgrade {false, true}]
                      [--extension-instance-name]
                      [--force-update]
                      [--no-auto-upgrade {false, true}]
                      [--no-auto-upgrade-minor-version {false, true}]
                      [--no-wait]
                      [--protected-settings]
                      [--provision-after-extensions]
                      [--settings]
                      [--version]

Examples

Set an extension which depends on two previously set extensions. That is, When a VMSS instance is created or reimaged, the customScript extension will be provisioned only after all extensions that it depends on have been provisioned. The extension need not depend on the other extensions for pre-requisite configurations.

az vmss extension set --vmss-name my-vmss --name customScript --resource-group my-group \
    --version 2.0 --publisher Microsoft.Azure.Extensions \
    --provision-after-extensions NetworkWatcherAgentLinux VMAccessForLinux  \
    --settings '{"commandToExecute": "echo testing"}'

Add an extension and enable automatic upgrade by the platform if there is a newer version of the extension available.

az vmss extension set -n extName --publisher publisher --vmss-name my-vmss -g my-group \ --enable-auto-upgrade true

Required Parameters

--name -n

Name of the extension.

Value from: az vm extension image list
--publisher

The name of the extension publisher.

--resource-group -g

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

--vmss-name

Scale set name. You can configure the default using az configure --defaults vmss=<name>.

Optional Parameters

--enable-auto-upgrade

Indicate the extension should be automatically upgraded by the platform if there is a newer version of the extension available.

Accepted values: false, true
--extension-instance-name

Name of extension instance, which can be customized. Default: name of the extension.

--force-update

Force to update even if the extension configuration has not changed.

Default value: False
--no-auto-upgrade
Deprecated

Option '--no-auto-upgrade' has been deprecated and will be removed in a future release. Use '--no-auto-upgrade-minor-version' instead.

If set, the extension service will not automatically pick or upgrade to the latest minor version, even if the extension is redeployed.

Accepted values: false, true
Default value: False
--no-auto-upgrade-minor-version

If set, the extension service will not automatically pick or upgrade to the latest minor version, even if the extension is redeployed.

Accepted values: false, true
Default value: False
--no-wait

Do not wait for the long-running operation to finish.

Default value: False
--protected-settings

Protected settings in JSON format for sensitive information like credentials. A JSON file path is also accepted.

--provision-after-extensions

Space-separated list of extension names after which this extension should be provisioned. These extensions must already be set on the vm.

--settings

Extension settings in JSON format. A JSON file path is also accepted.

--version

The version of the extension. To pin extension version to this value, please specify --no-auto-upgrade-minor-version.

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 vmss extension show

Show details on a VMSS extension.

az vmss extension show --name
                       --resource-group
                       --vmss-name

Examples

Show details on a VMSS extension. (autogenerated)

az vmss extension show --name MyExtension --resource-group MyResourceGroup --vmss-name MyVmss

Required Parameters

--name -n

Name of the extension.

--resource-group -g

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

--vmss-name

Scale set name. You can configure the default using az configure --defaults vmss=<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 vmss extension upgrade

Upgrade all extensions for all VMSS instances to the latest version.

az vmss extension upgrade [--ids]
                          [--name]
                          [--no-wait]
                          [--resource-group]
                          [--subscription]

Examples

Upgrade all extensions to the latest version.

az vmss extension upgrade -g MyResourceGroup -n MyVmss

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 -n

Scale set name. You can configure the default using az configure --defaults vmss=<name>.

--no-wait

Do not wait for the long-running operation to finish.

Default value: False
--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.