managed_instances
Creates, updates, deletes, gets or lists a managed_instances resource.
Overview
| Name | managed_instances |
| Type | Resource |
| Id | azure.sql.managed_instances |
Fields
The following fields are returned by SELECT queries:
- get
- list_by_instance_pool
- list_by_resource_group
- list
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
administratorLogin | string | Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation). |
administratorLoginPassword | string | The administrator login password (required for managed instance creation). |
administrators | object | The Azure Active Directory administrator can be utilized during instance creation and for instance updates, except for the azureADOnlyAuthentication property. To update the azureADOnlyAuthentication property, individual API must be used. |
authenticationMetadata | string | The managed instance's authentication metadata lookup mode. Known values are: "AzureAD", "Paired", and "Windows". (AzureAD, Paired, Windows) |
collation | string | Collation of the managed instance. |
createTime | string (date-time) | Specifies the point in time (ISO8601 format) of the Managed Instance creation. |
currentBackupStorageRedundancy | string | The storage account type used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
databaseFormat | string | Specifies the internal format of instance databases specific to the SQL engine version. Known values are: "AlwaysUpToDate", "SQLServer2022", and "SQLServer2025". (AlwaysUpToDate, SQLServer2022, SQLServer2025) |
dnsZone | string | The Dns Zone that the managed instance is in. |
dnsZonePartner | string | The resource id of another managed instance whose DNS zone this managed instance will share after creation. |
externalGovernanceStatus | string | Status of external governance. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
fullyQualifiedDomainName | string | The fully qualified domain name of the managed instance. |
hybridSecondaryUsage | string | Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
hybridSecondaryUsageDetected | string | Hybrid secondary usage detected. Possible values are 'Active' (customer does not meet the requirements to use the secondary as Passive DR) and 'Passive' (customer meets the requirements to use the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
identity | object | The Azure Active Directory identity of the managed instance. |
instancePoolId | string | The Id of the instance pool this managed server belongs to. |
isGeneralPurposeV2 | boolean | Whether or not this is a GPv2 variant of General Purpose edition. |
keyId | string | A CMK URI of the key to use for encryption. |
licenseType | string | The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses). Known values are: "LicenseIncluded" and "BasePrice". (LicenseIncluded, BasePrice) |
location | string | The geo-location where the resource lives. Required. |
maintenanceConfigurationId | string | Specifies maintenance configuration id to apply to this managed instance. |
managedInstanceCreateMode | string | Specifies the mode of database creation. Default: Regular instance creation. Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified. Known values are: "Default" and "PointInTimeRestore". (Default, PointInTimeRestore) |
memorySizeInGB | integer | Memory size in GB. Minimum value: 28. Maximum value: 870. Minimum and maximum value depend on the number of vCores and service tier. Read more about resource limits: https://aka.ms/mi-resource-limits-api _. |
minimalTlsVersion | string | Minimal TLS version. Allowed values: 'None', '1.0', '1.1', '1.2'. |
pricingModel | string | Pricing model of Managed Instance. Known values are: "Regular" and "Freemium". (Regular, Freemium) |
primaryUserAssignedIdentityId | string | The resource id of a user assigned identity to be used by default. |
privateEndpointConnections | array | List of private endpoint connections on a managed instance. |
provisioningState | string | Provisioning state of managed instance. Known values are: "Created", "InProgress", "Succeeded", "Failed", and "Canceled". (Created, InProgress, Succeeded, Failed, Canceled) |
proxyOverride | string | Connection type used for connecting to the instance. Known values are: "Proxy", "Redirect", and "Default". (Proxy, Redirect, Default) |
publicDataEndpointEnabled | boolean | Whether or not the public data endpoint is enabled. |
requestedBackupStorageRedundancy | string | The storage account type to be used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
requestedLogicalAvailabilityZone | string | Specifies the logical availability zone Managed Instance is pinned to. Known values are: "NoPreference", "1", "2", and "3". (NoPreference, 1, 2, 3) |
restorePointInTime | string (date-time) | Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database. |
servicePrincipal | object | The managed instance's service principal. |
sku | object | Managed instance SKU. Allowed values for sku.name: GP_Gen5 (General Purpose, Standard-series); GP_G8IM (General Purpose, Premium-series); GP_G8IH (General Purpose, Premium-series memory optimized); BC_Gen5 (Business Critical, Standard-Series); BC_G8IM (Business Critical, Premium-series); BC_G8IH (Business Critical, Premium-series memory optimized). |
sourceManagedInstanceId | string | The resource identifier of the source managed instance associated with create operation of this instance. |
state | string | The state of the managed instance. |
storageIOps | integer | Storage IOps. Minimum value: 300. Maximum value: 80000. Increments of 1 IOps allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageSizeInGB | integer | Storage size in GB. Minimum value: 32. Maximum value: 32768. Increments of 32 GB allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageThroughputMBps | integer | Storage throughput MBps parameter is not supported in the instance create/update operation. |
subnetId | string | Subnet resource ID for the managed instance. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
timezoneId | string | Id of the timezone. Allowed values are timezones supported by Windows. Windows keeps details on supported timezones, including the id, in registry under KEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones. You can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info. List of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell. An example of valid timezone id is "Pacific Standard Time" or "W. Europe Standard Time". |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
vCores | integer | The number of vCores. Allowed values: 4, 6, 8, 10, 12, 16, 20, 24, 32, 40, 48, 56, 64, 80, 96, 128. Supported vCores depends on the selected hardware family and service tier. |
virtualClusterId | string | Virtual cluster resource id for the Managed Instance. |
zoneRedundant | boolean | Whether or not the zone-redundancy is enabled. |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
administratorLogin | string | Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation). |
administratorLoginPassword | string | The administrator login password (required for managed instance creation). |
administrators | object | The Azure Active Directory administrator can be utilized during instance creation and for instance updates, except for the azureADOnlyAuthentication property. To update the azureADOnlyAuthentication property, individual API must be used. |
authenticationMetadata | string | The managed instance's authentication metadata lookup mode. Known values are: "AzureAD", "Paired", and "Windows". (AzureAD, Paired, Windows) |
collation | string | Collation of the managed instance. |
createTime | string (date-time) | Specifies the point in time (ISO8601 format) of the Managed Instance creation. |
currentBackupStorageRedundancy | string | The storage account type used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
databaseFormat | string | Specifies the internal format of instance databases specific to the SQL engine version. Known values are: "AlwaysUpToDate", "SQLServer2022", and "SQLServer2025". (AlwaysUpToDate, SQLServer2022, SQLServer2025) |
dnsZone | string | The Dns Zone that the managed instance is in. |
dnsZonePartner | string | The resource id of another managed instance whose DNS zone this managed instance will share after creation. |
externalGovernanceStatus | string | Status of external governance. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
fullyQualifiedDomainName | string | The fully qualified domain name of the managed instance. |
hybridSecondaryUsage | string | Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
hybridSecondaryUsageDetected | string | Hybrid secondary usage detected. Possible values are 'Active' (customer does not meet the requirements to use the secondary as Passive DR) and 'Passive' (customer meets the requirements to use the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
identity | object | The Azure Active Directory identity of the managed instance. |
instancePoolId | string | The Id of the instance pool this managed server belongs to. |
isGeneralPurposeV2 | boolean | Whether or not this is a GPv2 variant of General Purpose edition. |
keyId | string | A CMK URI of the key to use for encryption. |
licenseType | string | The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses). Known values are: "LicenseIncluded" and "BasePrice". (LicenseIncluded, BasePrice) |
location | string | The geo-location where the resource lives. Required. |
maintenanceConfigurationId | string | Specifies maintenance configuration id to apply to this managed instance. |
managedInstanceCreateMode | string | Specifies the mode of database creation. Default: Regular instance creation. Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified. Known values are: "Default" and "PointInTimeRestore". (Default, PointInTimeRestore) |
memorySizeInGB | integer | Memory size in GB. Minimum value: 28. Maximum value: 870. Minimum and maximum value depend on the number of vCores and service tier. Read more about resource limits: https://aka.ms/mi-resource-limits-api _. |
minimalTlsVersion | string | Minimal TLS version. Allowed values: 'None', '1.0', '1.1', '1.2'. |
pricingModel | string | Pricing model of Managed Instance. Known values are: "Regular" and "Freemium". (Regular, Freemium) |
primaryUserAssignedIdentityId | string | The resource id of a user assigned identity to be used by default. |
privateEndpointConnections | array | List of private endpoint connections on a managed instance. |
provisioningState | string | Provisioning state of managed instance. Known values are: "Created", "InProgress", "Succeeded", "Failed", and "Canceled". (Created, InProgress, Succeeded, Failed, Canceled) |
proxyOverride | string | Connection type used for connecting to the instance. Known values are: "Proxy", "Redirect", and "Default". (Proxy, Redirect, Default) |
publicDataEndpointEnabled | boolean | Whether or not the public data endpoint is enabled. |
requestedBackupStorageRedundancy | string | The storage account type to be used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
requestedLogicalAvailabilityZone | string | Specifies the logical availability zone Managed Instance is pinned to. Known values are: "NoPreference", "1", "2", and "3". (NoPreference, 1, 2, 3) |
restorePointInTime | string (date-time) | Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database. |
servicePrincipal | object | The managed instance's service principal. |
sku | object | Managed instance SKU. Allowed values for sku.name: GP_Gen5 (General Purpose, Standard-series); GP_G8IM (General Purpose, Premium-series); GP_G8IH (General Purpose, Premium-series memory optimized); BC_Gen5 (Business Critical, Standard-Series); BC_G8IM (Business Critical, Premium-series); BC_G8IH (Business Critical, Premium-series memory optimized). |
sourceManagedInstanceId | string | The resource identifier of the source managed instance associated with create operation of this instance. |
state | string | The state of the managed instance. |
storageIOps | integer | Storage IOps. Minimum value: 300. Maximum value: 80000. Increments of 1 IOps allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageSizeInGB | integer | Storage size in GB. Minimum value: 32. Maximum value: 32768. Increments of 32 GB allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageThroughputMBps | integer | Storage throughput MBps parameter is not supported in the instance create/update operation. |
subnetId | string | Subnet resource ID for the managed instance. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
timezoneId | string | Id of the timezone. Allowed values are timezones supported by Windows. Windows keeps details on supported timezones, including the id, in registry under KEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones. You can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info. List of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell. An example of valid timezone id is "Pacific Standard Time" or "W. Europe Standard Time". |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
vCores | integer | The number of vCores. Allowed values: 4, 6, 8, 10, 12, 16, 20, 24, 32, 40, 48, 56, 64, 80, 96, 128. Supported vCores depends on the selected hardware family and service tier. |
virtualClusterId | string | Virtual cluster resource id for the Managed Instance. |
zoneRedundant | boolean | Whether or not the zone-redundancy is enabled. |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
administratorLogin | string | Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation). |
administratorLoginPassword | string | The administrator login password (required for managed instance creation). |
administrators | object | The Azure Active Directory administrator can be utilized during instance creation and for instance updates, except for the azureADOnlyAuthentication property. To update the azureADOnlyAuthentication property, individual API must be used. |
authenticationMetadata | string | The managed instance's authentication metadata lookup mode. Known values are: "AzureAD", "Paired", and "Windows". (AzureAD, Paired, Windows) |
collation | string | Collation of the managed instance. |
createTime | string (date-time) | Specifies the point in time (ISO8601 format) of the Managed Instance creation. |
currentBackupStorageRedundancy | string | The storage account type used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
databaseFormat | string | Specifies the internal format of instance databases specific to the SQL engine version. Known values are: "AlwaysUpToDate", "SQLServer2022", and "SQLServer2025". (AlwaysUpToDate, SQLServer2022, SQLServer2025) |
dnsZone | string | The Dns Zone that the managed instance is in. |
dnsZonePartner | string | The resource id of another managed instance whose DNS zone this managed instance will share after creation. |
externalGovernanceStatus | string | Status of external governance. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
fullyQualifiedDomainName | string | The fully qualified domain name of the managed instance. |
hybridSecondaryUsage | string | Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
hybridSecondaryUsageDetected | string | Hybrid secondary usage detected. Possible values are 'Active' (customer does not meet the requirements to use the secondary as Passive DR) and 'Passive' (customer meets the requirements to use the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
identity | object | The Azure Active Directory identity of the managed instance. |
instancePoolId | string | The Id of the instance pool this managed server belongs to. |
isGeneralPurposeV2 | boolean | Whether or not this is a GPv2 variant of General Purpose edition. |
keyId | string | A CMK URI of the key to use for encryption. |
licenseType | string | The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses). Known values are: "LicenseIncluded" and "BasePrice". (LicenseIncluded, BasePrice) |
location | string | The geo-location where the resource lives. Required. |
maintenanceConfigurationId | string | Specifies maintenance configuration id to apply to this managed instance. |
managedInstanceCreateMode | string | Specifies the mode of database creation. Default: Regular instance creation. Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified. Known values are: "Default" and "PointInTimeRestore". (Default, PointInTimeRestore) |
memorySizeInGB | integer | Memory size in GB. Minimum value: 28. Maximum value: 870. Minimum and maximum value depend on the number of vCores and service tier. Read more about resource limits: https://aka.ms/mi-resource-limits-api _. |
minimalTlsVersion | string | Minimal TLS version. Allowed values: 'None', '1.0', '1.1', '1.2'. |
pricingModel | string | Pricing model of Managed Instance. Known values are: "Regular" and "Freemium". (Regular, Freemium) |
primaryUserAssignedIdentityId | string | The resource id of a user assigned identity to be used by default. |
privateEndpointConnections | array | List of private endpoint connections on a managed instance. |
provisioningState | string | Provisioning state of managed instance. Known values are: "Created", "InProgress", "Succeeded", "Failed", and "Canceled". (Created, InProgress, Succeeded, Failed, Canceled) |
proxyOverride | string | Connection type used for connecting to the instance. Known values are: "Proxy", "Redirect", and "Default". (Proxy, Redirect, Default) |
publicDataEndpointEnabled | boolean | Whether or not the public data endpoint is enabled. |
requestedBackupStorageRedundancy | string | The storage account type to be used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
requestedLogicalAvailabilityZone | string | Specifies the logical availability zone Managed Instance is pinned to. Known values are: "NoPreference", "1", "2", and "3". (NoPreference, 1, 2, 3) |
restorePointInTime | string (date-time) | Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database. |
servicePrincipal | object | The managed instance's service principal. |
sku | object | Managed instance SKU. Allowed values for sku.name: GP_Gen5 (General Purpose, Standard-series); GP_G8IM (General Purpose, Premium-series); GP_G8IH (General Purpose, Premium-series memory optimized); BC_Gen5 (Business Critical, Standard-Series); BC_G8IM (Business Critical, Premium-series); BC_G8IH (Business Critical, Premium-series memory optimized). |
sourceManagedInstanceId | string | The resource identifier of the source managed instance associated with create operation of this instance. |
state | string | The state of the managed instance. |
storageIOps | integer | Storage IOps. Minimum value: 300. Maximum value: 80000. Increments of 1 IOps allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageSizeInGB | integer | Storage size in GB. Minimum value: 32. Maximum value: 32768. Increments of 32 GB allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageThroughputMBps | integer | Storage throughput MBps parameter is not supported in the instance create/update operation. |
subnetId | string | Subnet resource ID for the managed instance. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
timezoneId | string | Id of the timezone. Allowed values are timezones supported by Windows. Windows keeps details on supported timezones, including the id, in registry under KEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones. You can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info. List of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell. An example of valid timezone id is "Pacific Standard Time" or "W. Europe Standard Time". |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
vCores | integer | The number of vCores. Allowed values: 4, 6, 8, 10, 12, 16, 20, 24, 32, 40, 48, 56, 64, 80, 96, 128. Supported vCores depends on the selected hardware family and service tier. |
virtualClusterId | string | Virtual cluster resource id for the Managed Instance. |
zoneRedundant | boolean | Whether or not the zone-redundancy is enabled. |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
administratorLogin | string | Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation). |
administratorLoginPassword | string | The administrator login password (required for managed instance creation). |
administrators | object | The Azure Active Directory administrator can be utilized during instance creation and for instance updates, except for the azureADOnlyAuthentication property. To update the azureADOnlyAuthentication property, individual API must be used. |
authenticationMetadata | string | The managed instance's authentication metadata lookup mode. Known values are: "AzureAD", "Paired", and "Windows". (AzureAD, Paired, Windows) |
collation | string | Collation of the managed instance. |
createTime | string (date-time) | Specifies the point in time (ISO8601 format) of the Managed Instance creation. |
currentBackupStorageRedundancy | string | The storage account type used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
databaseFormat | string | Specifies the internal format of instance databases specific to the SQL engine version. Known values are: "AlwaysUpToDate", "SQLServer2022", and "SQLServer2025". (AlwaysUpToDate, SQLServer2022, SQLServer2025) |
dnsZone | string | The Dns Zone that the managed instance is in. |
dnsZonePartner | string | The resource id of another managed instance whose DNS zone this managed instance will share after creation. |
externalGovernanceStatus | string | Status of external governance. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
fullyQualifiedDomainName | string | The fully qualified domain name of the managed instance. |
hybridSecondaryUsage | string | Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
hybridSecondaryUsageDetected | string | Hybrid secondary usage detected. Possible values are 'Active' (customer does not meet the requirements to use the secondary as Passive DR) and 'Passive' (customer meets the requirements to use the secondary as Passive DR). Known values are: "Active" and "Passive". (Active, Passive) |
identity | object | The Azure Active Directory identity of the managed instance. |
instancePoolId | string | The Id of the instance pool this managed server belongs to. |
isGeneralPurposeV2 | boolean | Whether or not this is a GPv2 variant of General Purpose edition. |
keyId | string | A CMK URI of the key to use for encryption. |
licenseType | string | The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses). Known values are: "LicenseIncluded" and "BasePrice". (LicenseIncluded, BasePrice) |
location | string | The geo-location where the resource lives. Required. |
maintenanceConfigurationId | string | Specifies maintenance configuration id to apply to this managed instance. |
managedInstanceCreateMode | string | Specifies the mode of database creation. Default: Regular instance creation. Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified. Known values are: "Default" and "PointInTimeRestore". (Default, PointInTimeRestore) |
memorySizeInGB | integer | Memory size in GB. Minimum value: 28. Maximum value: 870. Minimum and maximum value depend on the number of vCores and service tier. Read more about resource limits: https://aka.ms/mi-resource-limits-api _. |
minimalTlsVersion | string | Minimal TLS version. Allowed values: 'None', '1.0', '1.1', '1.2'. |
pricingModel | string | Pricing model of Managed Instance. Known values are: "Regular" and "Freemium". (Regular, Freemium) |
primaryUserAssignedIdentityId | string | The resource id of a user assigned identity to be used by default. |
privateEndpointConnections | array | List of private endpoint connections on a managed instance. |
provisioningState | string | Provisioning state of managed instance. Known values are: "Created", "InProgress", "Succeeded", "Failed", and "Canceled". (Created, InProgress, Succeeded, Failed, Canceled) |
proxyOverride | string | Connection type used for connecting to the instance. Known values are: "Proxy", "Redirect", and "Default". (Proxy, Redirect, Default) |
publicDataEndpointEnabled | boolean | Whether or not the public data endpoint is enabled. |
requestedBackupStorageRedundancy | string | The storage account type to be used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage). Known values are: "Geo", "Local", "Zone", and "GeoZone". (Geo, Local, Zone, GeoZone) |
requestedLogicalAvailabilityZone | string | Specifies the logical availability zone Managed Instance is pinned to. Known values are: "NoPreference", "1", "2", and "3". (NoPreference, 1, 2, 3) |
restorePointInTime | string (date-time) | Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database. |
servicePrincipal | object | The managed instance's service principal. |
sku | object | Managed instance SKU. Allowed values for sku.name: GP_Gen5 (General Purpose, Standard-series); GP_G8IM (General Purpose, Premium-series); GP_G8IH (General Purpose, Premium-series memory optimized); BC_Gen5 (Business Critical, Standard-Series); BC_G8IM (Business Critical, Premium-series); BC_G8IH (Business Critical, Premium-series memory optimized). |
sourceManagedInstanceId | string | The resource identifier of the source managed instance associated with create operation of this instance. |
state | string | The state of the managed instance. |
storageIOps | integer | Storage IOps. Minimum value: 300. Maximum value: 80000. Increments of 1 IOps allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageSizeInGB | integer | Storage size in GB. Minimum value: 32. Maximum value: 32768. Increments of 32 GB allowed only. Maximum value depends on the selected hardware family and number of vCores. |
storageThroughputMBps | integer | Storage throughput MBps parameter is not supported in the instance create/update operation. |
subnetId | string | Subnet resource ID for the managed instance. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
timezoneId | string | Id of the timezone. Allowed values are timezones supported by Windows. Windows keeps details on supported timezones, including the id, in registry under KEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones. You can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info. List of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell. An example of valid timezone id is "Pacific Standard Time" or "W. Europe Standard Time". |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
vCores | integer | The number of vCores. Allowed values: 4, 6, 8, 10, 12, 16, 20, 24, 32, 40, 48, 56, 64, 80, 96, 128. Supported vCores depends on the selected hardware family and service tier. |
virtualClusterId | string | Virtual cluster resource id for the Managed Instance. |
zoneRedundant | boolean | Whether or not the zone-redundancy is enabled. |
Methods
The following methods are available for this resource:
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
instance_pool_name | string | The name of the instance pool to be retrieved. Required. |
managed_instance_name | string | The name of the managed instance. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string | |
$expand | string | The child resources to include in the response. Default value is None. |
aggregationFunction | string | Aggregation function to be used, default value is 'sum'. Known values are: "avg", "min", "max", "stdev", and "sum". Default value is None. |
databases | string | Comma separated list of databases to be included into search. All DB's are included if this parameter is not specified. Default value is None. |
endTime | string | End time for observed period. Default value is None. |
interval | string | The time step to be used to summarize the metric values. Default value is PT1H. Known values are: "PT1H" and "P1D". Default value is None. |
numberOfQueries | integer | How many 'top queries' to return. Default is 5. Default value is None. |
observationMetric | string | Metric to be used for ranking top queries. Default is 'cpu'. Known values are: "cpu", "io", "logIo", "duration", and "dtu". Default value is None. |
replicaType | string | The type of replica to be failed over. Known values are: "Primary" and "ReadableSecondary". Default value is None. |
startTime | string | Start time for observed period. Default value is None. |
SELECT examples
- get
- list_by_instance_pool
- list_by_resource_group
- list
Gets a managed instance.
SELECT
id,
name,
administratorLogin,
administratorLoginPassword,
administrators,
authenticationMetadata,
collation,
createTime,
currentBackupStorageRedundancy,
databaseFormat,
dnsZone,
dnsZonePartner,
externalGovernanceStatus,
fullyQualifiedDomainName,
hybridSecondaryUsage,
hybridSecondaryUsageDetected,
identity,
instancePoolId,
isGeneralPurposeV2,
keyId,
licenseType,
location,
maintenanceConfigurationId,
managedInstanceCreateMode,
memorySizeInGB,
minimalTlsVersion,
pricingModel,
primaryUserAssignedIdentityId,
privateEndpointConnections,
provisioningState,
proxyOverride,
publicDataEndpointEnabled,
requestedBackupStorageRedundancy,
requestedLogicalAvailabilityZone,
restorePointInTime,
servicePrincipal,
sku,
sourceManagedInstanceId,
state,
storageIOps,
storageSizeInGB,
storageThroughputMBps,
subnetId,
systemData,
tags,
timezoneId,
type,
vCores,
virtualClusterId,
zoneRedundant
FROM azure.sql.managed_instances
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND managed_instance_name = '{{ managed_instance_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
AND $expand = '{{ $expand }}'
;
Gets a list of all managed instances in an instance pool.
SELECT
id,
name,
administratorLogin,
administratorLoginPassword,
administrators,
authenticationMetadata,
collation,
createTime,
currentBackupStorageRedundancy,
databaseFormat,
dnsZone,
dnsZonePartner,
externalGovernanceStatus,
fullyQualifiedDomainName,
hybridSecondaryUsage,
hybridSecondaryUsageDetected,
identity,
instancePoolId,
isGeneralPurposeV2,
keyId,
licenseType,
location,
maintenanceConfigurationId,
managedInstanceCreateMode,
memorySizeInGB,
minimalTlsVersion,
pricingModel,
primaryUserAssignedIdentityId,
privateEndpointConnections,
provisioningState,
proxyOverride,
publicDataEndpointEnabled,
requestedBackupStorageRedundancy,
requestedLogicalAvailabilityZone,
restorePointInTime,
servicePrincipal,
sku,
sourceManagedInstanceId,
state,
storageIOps,
storageSizeInGB,
storageThroughputMBps,
subnetId,
systemData,
tags,
timezoneId,
type,
vCores,
virtualClusterId,
zoneRedundant
FROM azure.sql.managed_instances
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND instance_pool_name = '{{ instance_pool_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
AND $expand = '{{ $expand }}'
;
Gets a list of managed instances in a resource group.
SELECT
id,
name,
administratorLogin,
administratorLoginPassword,
administrators,
authenticationMetadata,
collation,
createTime,
currentBackupStorageRedundancy,
databaseFormat,
dnsZone,
dnsZonePartner,
externalGovernanceStatus,
fullyQualifiedDomainName,
hybridSecondaryUsage,
hybridSecondaryUsageDetected,
identity,
instancePoolId,
isGeneralPurposeV2,
keyId,
licenseType,
location,
maintenanceConfigurationId,
managedInstanceCreateMode,
memorySizeInGB,
minimalTlsVersion,
pricingModel,
primaryUserAssignedIdentityId,
privateEndpointConnections,
provisioningState,
proxyOverride,
publicDataEndpointEnabled,
requestedBackupStorageRedundancy,
requestedLogicalAvailabilityZone,
restorePointInTime,
servicePrincipal,
sku,
sourceManagedInstanceId,
state,
storageIOps,
storageSizeInGB,
storageThroughputMBps,
subnetId,
systemData,
tags,
timezoneId,
type,
vCores,
virtualClusterId,
zoneRedundant
FROM azure.sql.managed_instances
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
AND $expand = '{{ $expand }}'
;
Gets a list of all managed instances in the subscription.
SELECT
id,
name,
administratorLogin,
administratorLoginPassword,
administrators,
authenticationMetadata,
collation,
createTime,
currentBackupStorageRedundancy,
databaseFormat,
dnsZone,
dnsZonePartner,
externalGovernanceStatus,
fullyQualifiedDomainName,
hybridSecondaryUsage,
hybridSecondaryUsageDetected,
identity,
instancePoolId,
isGeneralPurposeV2,
keyId,
licenseType,
location,
maintenanceConfigurationId,
managedInstanceCreateMode,
memorySizeInGB,
minimalTlsVersion,
pricingModel,
primaryUserAssignedIdentityId,
privateEndpointConnections,
provisioningState,
proxyOverride,
publicDataEndpointEnabled,
requestedBackupStorageRedundancy,
requestedLogicalAvailabilityZone,
restorePointInTime,
servicePrincipal,
sku,
sourceManagedInstanceId,
state,
storageIOps,
storageSizeInGB,
storageThroughputMBps,
subnetId,
systemData,
tags,
timezoneId,
type,
vCores,
virtualClusterId,
zoneRedundant
FROM azure.sql.managed_instances
WHERE subscription_id = '{{ subscription_id }}' -- required
AND $expand = '{{ $expand }}'
;
INSERT examples
- create_or_update
- Manifest
Creates or updates a managed instance.
INSERT INTO azure.sql.managed_instances (
tags,
location,
properties,
identity,
sku,
resource_group_name,
managed_instance_name,
subscription_id
)
SELECT
'{{ tags }}',
'{{ location }}' /* required */,
'{{ properties }}',
'{{ identity }}',
'{{ sku }}',
'{{ resource_group_name }}',
'{{ managed_instance_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
identity,
location,
properties,
sku,
systemData,
tags,
type
;
# Description fields are for documentation purposes
- name: managed_instances
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the managed_instances resource.
- name: managed_instance_name
value: "{{ managed_instance_name }}"
description: Required parameter for the managed_instances resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the managed_instances resource.
- name: tags
value: "{{ tags }}"
description: |
Resource tags.
- name: location
value: "{{ location }}"
description: |
The geo-location where the resource lives. Required.
- name: properties
description: |
Resource properties.
value:
provisioningState: "{{ provisioningState }}"
managedInstanceCreateMode: "{{ managedInstanceCreateMode }}"
fullyQualifiedDomainName: "{{ fullyQualifiedDomainName }}"
isGeneralPurposeV2: {{ isGeneralPurposeV2 }}
administratorLogin: "{{ administratorLogin }}"
administratorLoginPassword: "{{ administratorLoginPassword }}"
subnetId: "{{ subnetId }}"
state: "{{ state }}"
licenseType: "{{ licenseType }}"
hybridSecondaryUsage: "{{ hybridSecondaryUsage }}"
hybridSecondaryUsageDetected: "{{ hybridSecondaryUsageDetected }}"
vCores: {{ vCores }}
storageSizeInGB: {{ storageSizeInGB }}
storageIOps: {{ storageIOps }}
storageThroughputMBps: {{ storageThroughputMBps }}
memorySizeInGB: {{ memorySizeInGB }}
collation: "{{ collation }}"
dnsZone: "{{ dnsZone }}"
dnsZonePartner: "{{ dnsZonePartner }}"
publicDataEndpointEnabled: {{ publicDataEndpointEnabled }}
sourceManagedInstanceId: "{{ sourceManagedInstanceId }}"
restorePointInTime: "{{ restorePointInTime }}"
proxyOverride: "{{ proxyOverride }}"
timezoneId: "{{ timezoneId }}"
instancePoolId: "{{ instancePoolId }}"
maintenanceConfigurationId: "{{ maintenanceConfigurationId }}"
privateEndpointConnections:
- id: "{{ id }}"
properties:
privateEndpoint:
id: "{{ id }}"
privateLinkServiceConnectionState:
status: "{{ status }}"
description: "{{ description }}"
actionsRequired: "{{ actionsRequired }}"
provisioningState: "{{ provisioningState }}"
minimalTlsVersion: "{{ minimalTlsVersion }}"
currentBackupStorageRedundancy: "{{ currentBackupStorageRedundancy }}"
requestedBackupStorageRedundancy: "{{ requestedBackupStorageRedundancy }}"
zoneRedundant: {{ zoneRedundant }}
primaryUserAssignedIdentityId: "{{ primaryUserAssignedIdentityId }}"
keyId: "{{ keyId }}"
administrators:
administratorType: "{{ administratorType }}"
principalType: "{{ principalType }}"
login: "{{ login }}"
sid: "{{ sid }}"
tenantId: "{{ tenantId }}"
azureADOnlyAuthentication: {{ azureADOnlyAuthentication }}
servicePrincipal:
principalId: "{{ principalId }}"
clientId: "{{ clientId }}"
tenantId: "{{ tenantId }}"
type: "{{ type }}"
virtualClusterId: "{{ virtualClusterId }}"
externalGovernanceStatus: "{{ externalGovernanceStatus }}"
pricingModel: "{{ pricingModel }}"
createTime: "{{ createTime }}"
authenticationMetadata: "{{ authenticationMetadata }}"
databaseFormat: "{{ databaseFormat }}"
requestedLogicalAvailabilityZone: "{{ requestedLogicalAvailabilityZone }}"
- name: identity
description: |
The Azure Active Directory identity of the managed instance.
value:
userAssignedIdentities: "{{ userAssignedIdentities }}"
principalId: "{{ principalId }}"
type: "{{ type }}"
tenantId: "{{ tenantId }}"
- name: sku
description: |
Managed instance SKU. Allowed values for sku.name: GP_Gen5 (General Purpose, Standard-series); GP_G8IM (General Purpose, Premium-series); GP_G8IH (General Purpose, Premium-series memory optimized); BC_Gen5 (Business Critical, Standard-Series); BC_G8IM (Business Critical, Premium-series); BC_G8IH (Business Critical, Premium-series memory optimized).
value:
name: "{{ name }}"
tier: "{{ tier }}"
size: "{{ size }}"
family: "{{ family }}"
capacity: {{ capacity }}
UPDATE examples
- update
Updates a managed instance.
UPDATE azure.sql.managed_instances
SET
sku = '{{ sku }}',
identity = '{{ identity }}',
properties = '{{ properties }}',
tags = '{{ tags }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND managed_instance_name = '{{ managed_instance_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
identity,
location,
properties,
sku,
systemData,
tags,
type;
REPLACE examples
- create_or_update
Creates or updates a managed instance.
REPLACE azure.sql.managed_instances
SET
tags = '{{ tags }}',
location = '{{ location }}',
properties = '{{ properties }}',
identity = '{{ identity }}',
sku = '{{ sku }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND managed_instance_name = '{{ managed_instance_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
identity,
location,
properties,
sku,
systemData,
tags,
type;
DELETE examples
- delete
Deletes a managed instance.
DELETE FROM azure.sql.managed_instances
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND managed_instance_name = '{{ managed_instance_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;
Lifecycle Methods
- list_by_managed_instance
- list_outbound_network_dependencies_by_managed_instance
- failover
- reevaluate_inaccessible_database_state
- refresh_status
- start
- stop
- validate_azure_key_vault_encryption_key
Get top resource consuming queries of a managed instance.
EXEC azure.sql.managed_instances.list_by_managed_instance
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required,
@numberOfQueries='{{ numberOfQueries }}',
@databases='{{ databases }}',
@startTime='{{ startTime }}',
@endTime='{{ endTime }}',
@interval='{{ interval }}',
@aggregationFunction='{{ aggregationFunction }}',
@observationMetric='{{ observationMetric }}'
;
Gets the collection of outbound network dependencies for the given managed instance.
EXEC azure.sql.managed_instances.list_outbound_network_dependencies_by_managed_instance
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Failovers a managed instance.
EXEC azure.sql.managed_instances.failover
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required,
@replicaType='{{ replicaType }}'
;
Reevaluates the inaccessibility state of all managed databases.
EXEC azure.sql.managed_instances.reevaluate_inaccessible_database_state
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Refresh external governance enablement status.
EXEC azure.sql.managed_instances.refresh_status
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Starts the managed instance.
EXEC azure.sql.managed_instances.start
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Stops the managed instance.
EXEC azure.sql.managed_instances.stop
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Validates customer managed key.
EXEC azure.sql.managed_instances.validate_azure_key_vault_encryption_key
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"tdeKeyUri": "{{ tdeKeyUri }}"
}'
;