az sql instance-pool

Manage instance pools.

Commands

az sql instance-pool create

Create an instance pool.

az sql instance-pool delete

Delete an instance pool.

az sql instance-pool list

List available instance pools.

az sql instance-pool show

Get the details for an instance pool.

az sql instance-pool update

Update an instance pool.

az sql instance-pool wait

Wait for an instance pool to reach a desired state.

az sql instance-pool create

Create an instance pool.

az sql instance-pool create --capacity
                            --edition
                            --family
                            --license-type {BasePrice, LicenseIncluded}
                            --location
                            --name
                            --resource-group
                            --subnet
                            [--no-wait]
                            [--subscription]
                            [--tags]
                            [--vnet-name]

Examples

Example to create an instance pool (include --no-wait in the end to get an asynchronous experience)

az sql instance-pool create -g resource_group_name -n instance_pool_name -l location --subnet /subscriptions/{SubID}/resourceGroups/{ResourceGroup}/providers/Microsoft.Network/virtualNetworks/{VNETName}/subnets/{SubnetName} --license-type LicenseIncluded --capacity 8 -e GeneralPurpose -f Gen5 --no-wait

Example to create an instance pool with subnet name and vnet-name

az sql instance-pool create --license-type LicenseIncluded -l northcentralus -n myinstancepool -c 8 -e GeneralPurpose -f Gen5 -g billingPools --subnet mysubnetname --vnet-name myvnetname

Required Parameters

--capacity -c

Capacity of the instance pool in vcores.

--edition --tier -e

The edition component of the sku. Allowed value: GeneralPurpose.

--family -f

The compute generation component of the sku. Allowed value: Gen5.

--license-type

The license type to apply for this instance pool.

accepted values: BasePrice, LicenseIncluded
--location -l

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

--name -n

Instance Pool Name.

--resource-group -g

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

--subnet

Name or ID of the subnet that allows access to an Instance Pool. If subnet name is provided, --vnet-name must be provided.

Optional Parameters

--no-wait

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

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

--vnet-name

The virtual network name.

az sql instance-pool delete

Delete an instance pool.

az sql instance-pool delete --name
                            --resource-group
                            [--no-wait]
                            [--subscription]
                            [--yes]

Examples

Delete an instance pool

az sql instance-pool delete -g mygroup -n myinstancepool --yes

Required Parameters

--name -n

Instance Pool Name.

--resource-group -g

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

Optional Parameters

--no-wait

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

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

az sql instance-pool list

List available instance pools.

az sql instance-pool list [--query-examples]
                          [--resource-group]
                          [--subscription]

Examples

List all instance pools in the current subscription.

az sql instance-pool list

List all instance pools in a resource group.

az sql instance-pool list -g mygroup

Optional Parameters

--query-examples

Recommend JMESPath string for you. You can copy one of the query and paste it after --query parameter within double quotation marks to see the results. You can add one or more positional keywords so that we can give suggestions based on these key words.

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

az sql instance-pool show

Get the details for an instance pool.

az sql instance-pool show --name
                          --resource-group
                          [--query-examples]
                          [--subscription]

Examples

Get the details for an instance pool

az sql instance-pool show -g mygroup -n myinstancepool

Required Parameters

--name -n

Instance Pool Name.

--resource-group -g

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

Optional Parameters

--query-examples

Recommend JMESPath string for you. You can copy one of the query and paste it after --query parameter within double quotation marks to see the results. You can add one or more positional keywords so that we can give suggestions based on these key words.

--subscription

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

az sql instance-pool update

Update an instance pool.

az sql instance-pool update --name
                            --resource-group
                            [--subscription]
                            [--tags]

Examples

Update an instance pool with new tags (make sure they are space separated if there are multiple tags)

az sql instance-pool update -n myinstancepool -g mygroup --tags mykey1=myvalue1 mykey2=myvalue2

Clear the tags assigned to an instance pool

az sql instance-pool update -n myinstancepool -g mygroup --tags ""

Required Parameters

--name -n

Instance Pool Name.

--resource-group -g

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

Optional Parameters

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

az sql instance-pool wait

Wait for an instance pool to reach a desired state.

az sql instance-pool wait --name
                          --resource-group
                          [--created]
                          [--custom]
                          [--deleted]
                          [--exists]
                          [--interval]
                          [--subscription]
                          [--timeout]
                          [--updated]

Examples

Wait until an instance pool gets created.

az sql instance-pool wait -n myinstancepool -g mygroup --created

Required Parameters

--name -n

Instance Pool Name.

--resource-group -g

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

Optional Parameters

--created

Wait until created with 'provisioningState' at 'Succeeded'.

--custom

Wait until the condition satisfies a custom JMESPath query. E.g. provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running'].

--deleted

Wait until deleted.

--exists

Wait until the resource exists.

--interval

Polling interval in seconds.

default value: 30
--subscription

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

--timeout

Maximum wait in seconds.

default value: 3600
--updated

Wait until updated with provisioningState at 'Succeeded'.