Servers - Create
建立新的伺服器或更新現有的伺服器。 更新動作會覆寫現有的伺服器。
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforMySQL/flexibleServers/{serverName}?api-version=2024-12-30
URI 參數
| 名稱 | 位於 | 必要 | 類型 | Description |
|---|---|---|---|---|
|
resource
|
path | True |
string minLength: 1maxLength: 90 |
資源群組的名稱。 名稱不區分大小寫。 |
|
server
|
path | True |
string minLength: 1maxLength: 63 pattern: ^[a-z0-9][-a-z0-9]*(? |
伺服器的名稱。 |
|
subscription
|
path | True |
string (uuid) |
目標訂用帳戶的標識碼。 此值必須是 UUID。 |
|
api-version
|
query | True |
string minLength: 1 |
用於此作業的 API 版本。 |
要求本文
| 名稱 | 必要 | 類型 | Description |
|---|---|---|---|
| location | True |
string |
資源所在的地理位置 |
| identity |
伺服器的 Cmk 身分識別。 |
||
| properties.administratorLogin |
string |
系統管理員的伺服器登入名稱。 只有在建立伺服器時才能指定 (而且是建立的必要專案)。 |
|
| properties.administratorLoginPassword |
string (password) |
系統管理員登入的密碼(建立伺服器所需的密碼)。 |
|
| properties.availabilityZone |
string |
伺服器的可用性區域資訊。 |
|
| properties.backup |
備份伺服器的相關屬性。 |
||
| properties.createMode |
建立新 MySQL 伺服器的模式。 |
||
| properties.dataEncryption |
CMK 的數據加密。 |
||
| properties.databasePort |
integer (int32) |
伺服器資料庫埠。 只能在建立伺服器時指定。 |
|
| properties.highAvailability |
伺服器的高可用性相關屬性。 |
||
| properties.importSourceProperties |
從記憶體匯入的來源屬性。 |
||
| properties.maintenancePolicy |
伺服器的維護原則。 |
||
| properties.maintenanceWindow |
伺服器的維護時間範圍。 已知問題:無法在伺服器建立期間設定,或在伺服器更新期間以其他屬性更新;必須個別更新。 |
||
| properties.network |
伺服器的網路相關屬性。 |
||
| properties.replicationRole |
複寫角色。 |
||
| properties.restorePointInTime |
string (date-time) |
還原點建立時間(ISO8601格式),指定要還原的時間。 |
|
| properties.sourceServerResourceId |
string |
來源 MySQL 伺服器識別碼。 |
|
| properties.storage |
伺服器的記憶體相關屬性。 |
||
| properties.version |
MySQL 的主要版本。 8.0.21 代表 MySQL 8.0、5.7.44 代表 MySQL 5.7 |
||
| sku |
伺服器的 SKU(定價層)。 |
||
| tags |
object |
資源標籤。 |
回應
| 名稱 | 類型 | Description |
|---|---|---|
| 200 OK |
資源 'Server' 更新作業成功 |
|
| 201 Created |
資源 'Server' 建立作業成功 標題
|
|
| 202 Accepted |
已接受資源作業。 標題
|
|
| Other Status Codes |
未預期的錯誤回應。 |
安全性
azure_auth
Azure Active Directory OAuth2 Flow。
類型:
oauth2
Flow:
implicit
授權 URL:
https://login.microsoftonline.com/common/oauth2/authorize
範圍
| 名稱 | Description |
|---|---|
| user_impersonation | 模擬您的用戶帳戶 |
範例
| Create a new server |
| Create a replica server |
| Create a server as a point in time restore |
| Create a server with byok |
| Create a server with non-default database port |
Create a new server
範例要求
PUT https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver?api-version=2024-12-30
{
"location": "southeastasia",
"properties": {
"administratorLogin": "cloudsa",
"administratorLoginPassword": "your_password",
"availabilityZone": "1",
"backup": {
"backupIntervalHours": 24,
"backupRetentionDays": 7,
"geoRedundantBackup": "Disabled"
},
"createMode": "Default",
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3"
},
"storage": {
"autoGrow": "Disabled",
"iops": 600,
"storageRedundancy": "ZoneRedundancy",
"storageSizeGB": 100
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
範例回覆
{
"name": "mysqltestserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "1",
"backup": {
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-17T06:11:38.4150019+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "mysqltestserver.database.mysql.azure.com",
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3",
"state": "Healthy"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 600,
"storageRedundancy": "ZoneRedundancy",
"storageSizeGB": 100,
"storageSku": "Premium_ZRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
{
"name": "mysqltestserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "1",
"backup": {
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-17T06:11:38.4150019+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "mysqltestserver.database.mysql.azure.com",
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3",
"state": "Healthy"
},
"maintenancePolicy": {
"patchStrategy": "Regular"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 600,
"storageRedundancy": "ZoneRedundancy",
"storageSizeGB": 100,
"storageSku": "Premium_ZRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
Create a replica server
範例要求
PUT https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testgr/providers/Microsoft.DBforMySQL/flexibleServers/replica-server?api-version=2024-12-30
{
"location": "SoutheastAsia",
"properties": {
"createMode": "Replica",
"sourceServerResourceId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testgr/providers/Microsoft.DBforMySQL/flexibleServers/source-server"
}
}
範例回覆
{
"name": "replica-server",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testgr/providers/Microsoft.DBforMySQL/flexibleServers/replica-server",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "3",
"backup": {
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-24T08:19:18.5729164+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "replica-server.database.mysql.azure.com",
"highAvailability": {
"mode": "Disabled",
"state": "NotEnabled"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 0,
"replicationRole": "Replica",
"sourceServerResourceId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testgr/providers/Microsoft.DBforMySQL/flexibleServers/source-server",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 360,
"storageRedundancy": "LocalRedundancy",
"storageSizeGB": 20,
"storageSku": "Premium_LRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"ElasticServer": "1"
}
}
{
"name": "replica-server",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testgr/providers/Microsoft.DBforMySQL/flexibleServers/replica-server",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "3",
"backup": {
"backupIntervalHours": 24,
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-24T08:19:18.5729164+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "replica-server.database.mysql.azure.com",
"highAvailability": {
"mode": "Disabled",
"state": "NotEnabled"
},
"maintenancePolicy": {
"patchStrategy": "Regular"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 0,
"replicationRole": "Replica",
"sourceServerResourceId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testgr/providers/Microsoft.DBforMySQL/flexibleServers/source-server",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 360,
"storageRedundancy": "LocalRedundancy",
"storageSizeGB": 20,
"storageSku": "Premium_LRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"ElasticServer": "1"
}
}
Create a server as a point in time restore
範例要求
PUT https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TargetResourceGroup/providers/Microsoft.DBforMySQL/flexibleServers/targetserver?api-version=2024-12-30
{
"location": "SoutheastAsia",
"properties": {
"createMode": "PointInTimeRestore",
"restorePointInTime": "2021-06-24T00:00:37.467Z",
"sourceServerResourceId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/SourceResourceGroup/providers/Microsoft.DBforMySQL/flexibleServers/sourceserver"
},
"sku": {
"name": "Standard_D14_v2",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
範例回覆
{
"name": "targetserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TargetResourceGroup/providers/Microsoft.DBforMySQL/flexibleServers/targetserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "adminuser",
"availabilityZone": "1",
"backup": {
"backupIntervalHours": 24,
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-24T00:15:24.00+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "targetserver.database.mysql.azure.com",
"highAvailability": {
"mode": "Disabled",
"state": "NotEnabled"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 360,
"storageRedundancy": "LocalRedundancy",
"storageSizeGB": 20,
"storageSku": "Premium_LRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
{
"name": "targetserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TargetResourceGroup/providers/Microsoft.DBforMySQL/flexibleServers/targetserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "adminuser",
"availabilityZone": "1",
"backup": {
"backupIntervalHours": 24,
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-24T00:15:24.00+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "targetserver.database.mysql.azure.com",
"highAvailability": {
"mode": "Disabled",
"state": "NotEnabled"
},
"maintenancePolicy": {
"patchStrategy": "Regular"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 360,
"storageRedundancy": "LocalRedundancy",
"storageSizeGB": 20,
"storageSku": "Premium_LRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
Create a server with byok
範例要求
PUT https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver?api-version=2024-12-30
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/test-identity": {}
}
},
"location": "southeastasia",
"properties": {
"administratorLogin": "cloudsa",
"administratorLoginPassword": "your_password",
"availabilityZone": "1",
"backup": {
"backupIntervalHours": 24,
"backupRetentionDays": 7,
"geoRedundantBackup": "Disabled"
},
"createMode": "Default",
"dataEncryption": {
"type": "AzureKeyVault",
"geoBackupKeyURI": "https://test-geo.vault.azure.net/keys/key/c8a92236622244c0a4fdb892666f671a",
"geoBackupUserAssignedIdentityId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/test-geo-identity",
"primaryKeyURI": "https://test.vault.azure.net/keys/key/c8a92236622244c0a4fdb892666f671a",
"primaryUserAssignedIdentityId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/test-identity"
},
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3"
},
"storage": {
"autoGrow": "Disabled",
"iops": 600,
"storageRedundancy": "LocalRedundancy",
"storageSizeGB": 100
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
範例回覆
{
"name": "mysqltestserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "1",
"backup": {
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-17T06:11:38.4150019+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "mysqltestserver.database.mysql.azure.com",
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3",
"state": "Healthy"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 600,
"storageRedundancy": "ZoneRedundancy",
"storageSizeGB": 100,
"storageSku": "Premium_ZRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
{
"name": "mysqltestserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "1",
"backup": {
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-17T06:11:38.4150019+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 3306,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "mysqltestserver.database.mysql.azure.com",
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3",
"state": "Healthy"
},
"maintenancePolicy": {
"patchStrategy": "Regular"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 600,
"storageRedundancy": "ZoneRedundancy",
"storageSizeGB": 100,
"storageSku": "Premium_ZRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
Create a server with non-default database port
範例要求
PUT https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver?api-version=2024-12-30
{
"location": "southeastasia",
"properties": {
"administratorLogin": "cloudsa",
"administratorLoginPassword": "your_password",
"availabilityZone": "1",
"backup": {
"backupIntervalHours": 24,
"backupRetentionDays": 7,
"geoRedundantBackup": "Disabled"
},
"createMode": "Default",
"databasePort": 8888,
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3"
},
"storage": {
"autoGrow": "Disabled",
"iops": 600,
"storageRedundancy": "LocalRedundancy",
"storageSizeGB": 100
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
範例回覆
{
"name": "mysqltestserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "1",
"backup": {
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-17T06:11:38.4150019+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 8888,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "mysqltestserver.database.mysql.azure.com",
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3",
"state": "Healthy"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 600,
"storageRedundancy": "ZoneRedundancy",
"storageSizeGB": 100,
"storageSku": "Premium_ZRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
{
"name": "mysqltestserver",
"type": "Microsoft.DBforMySQL/flexibleServers",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBforMySQL/flexibleServers/mysqltestserver",
"location": "Southeast Asia",
"properties": {
"administratorLogin": "cloudsa",
"availabilityZone": "1",
"backup": {
"backupRetentionDays": 7,
"earliestRestoreDate": "2021-06-17T06:11:38.4150019+00:00",
"geoRedundantBackup": "Disabled"
},
"databasePort": 8888,
"fullVersion": "5.7.44",
"fullyQualifiedDomainName": "mysqltestserver.database.mysql.azure.com",
"highAvailability": {
"mode": "ZoneRedundant",
"standbyAvailabilityZone": "3",
"state": "Healthy"
},
"maintenanceWindow": {
"batchOfMaintenance": "Default",
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"network": {
"publicNetworkAccess": "Enabled"
},
"replicaCapacity": 10,
"replicationRole": "None",
"state": "Ready",
"storage": {
"autoGrow": "Enabled",
"iops": 600,
"storageRedundancy": "ZoneRedundancy",
"storageSizeGB": 100,
"storageSku": "Premium_ZRS"
},
"version": "5.7"
},
"sku": {
"name": "Standard_D2ds_v4",
"tier": "GeneralPurpose"
},
"tags": {
"num": "1"
}
}
定義
Backup
伺服器的記憶體配置檔屬性
| 名稱 | 類型 | 預設值 | Description |
|---|---|---|---|
| backupIntervalHours |
integer (int32) |
伺服器的備份間隔時數。 |
|
| backupRetentionDays |
integer (int32) |
伺服器的備份保留天數。 |
|
| earliestRestoreDate |
string (date-time) |
最早的還原點建立時間(ISO8601格式) |
|
| geoRedundantBackup | Disabled |
是否啟用異地備援備份。 |
BatchOfMaintenance
啟用伺服器的自定義託管維護時段時的維護批次。
| 值 | Description |
|---|---|
| Default | |
| Batch1 | |
| Batch2 |
createdByType
建立資源的身分識別類型。
| 值 | Description |
|---|---|
| User | |
| Application | |
| ManagedIdentity | |
| Key |
CreateMode
建立新 MySQL 伺服器的模式。
| 值 | Description |
|---|---|
| Default | |
| PointInTimeRestore | |
| Replica | |
| GeoRestore |
DataEncryption
cmk 的日期加密。
| 名稱 | 類型 | Description |
|---|---|---|
| geoBackupKeyURI |
string |
異地備份密鑰 URI 作為金鑰保存庫無法跨區域,需要在與異地備份相同的區域中使用 cmk |
| geoBackupUserAssignedIdentityId |
string |
異地備份使用者身分識別資源標識碼作為身分識別無法跨區域,需要在與異地備份相同的區域中的身分識別 |
| primaryKeyURI |
string |
主鍵 URI |
| primaryUserAssignedIdentityId |
string |
主要使用者身分識別資源標識碼 |
| type |
密鑰類型:啟用 cmk 的 AzureKeyVault、適用於停用 cmk 的 SystemManaged。 |
DataEncryptionType
密鑰類型:啟用 cmk 的 AzureKeyVault、適用於停用 cmk 的 SystemManaged。
| 值 | Description |
|---|---|
| AzureKeyVault | |
| SystemManaged |
EnableStatusEnum
列舉,指出值為 'Enabled' 或 'Disabled'
| 值 | Description |
|---|---|
| Enabled | |
| Disabled |
ErrorAdditionalInfo
資源管理錯誤其他資訊。
| 名稱 | 類型 | Description |
|---|---|---|
| info |
object |
其他資訊。 |
| type |
string |
其他信息類型。 |
ErrorDetail
錯誤詳細數據。
| 名稱 | 類型 | Description |
|---|---|---|
| additionalInfo |
錯誤其他資訊。 |
|
| code |
string |
錯誤碼。 |
| details |
錯誤詳細數據。 |
|
| message |
string |
錯誤訊息。 |
| target |
string |
錯誤目標。 |
ErrorResponse
錯誤回應
| 名稱 | 類型 | Description |
|---|---|---|
| error |
error 物件。 |
HighAvailability
伺服器的高可用性屬性
| 名稱 | 類型 | Description |
|---|---|---|
| mode |
伺服器的高可用性模式。 |
|
| standbyAvailabilityZone |
string |
待命伺服器的可用性區域。 |
| state |
伺服器高可用性的狀態。 |
HighAvailabilityMode
伺服器的高可用性模式。
| 值 | Description |
|---|---|
| Disabled | |
| ZoneRedundant | |
| SameZone |
HighAvailabilityState
伺服器高可用性的狀態。
| 值 | Description |
|---|---|
| NotEnabled | |
| CreatingStandby | |
| Healthy | |
| FailingOver | |
| RemovingStandby |
ImportSourceProperties
匯入來源相關屬性。
| 名稱 | 類型 | Description |
|---|---|---|
| dataDirPath |
string |
記憶體中資料目錄的相對路徑。 |
| sasToken |
string (password) |
用於存取來源記憶體的 Sas 令牌。 SAS 令牌需要讀取和列表許可權。 |
| storageType |
匯入來源的儲存類型。 |
|
| storageUrl |
string |
匯入來源記憶體的 URI。 |
ImportSourceStorageType
匯入來源的儲存類型。
| 值 | Description |
|---|---|
| AzureBlob |
MaintenancePolicy
伺服器的維護原則。
| 名稱 | 類型 | Description |
|---|---|---|
| patchStrategy |
此伺服器的修補程式策略 |
MaintenanceWindow
伺服器的維護時間範圍。
| 名稱 | 類型 | Description |
|---|---|---|
| batchOfMaintenance |
啟用伺服器的自定義託管維護時段時的維護批次。 |
|
| customWindow |
string |
指出是否啟用或停用自定義視窗 |
| dayOfWeek |
integer (int32) |
維護時段的星期數 |
| startHour |
integer (int32) |
維護時段的開始時間 |
| startMinute |
integer (int32) |
維護時段的開始分鐘 |
ManagedServiceIdentityType
受控服務識別的類型。
| 值 | Description |
|---|---|
| UserAssigned |
MySQLServerIdentity
設定自備金鑰身分識別的屬性
| 名稱 | 類型 | Description |
|---|---|---|
| principalId |
string |
KeyVault 中的 ObjectId |
| tenantId |
string |
KeyVault 中的 TenantId |
| type |
受控服務識別的類型。 |
|
| userAssignedIdentities |
<string,
User |
使用者指派身分識別的元數據。 |
MySQLServerSku
伺服器的計費資訊相關信息。
| 名稱 | 類型 | Description |
|---|---|---|
| name |
string |
sku 的名稱,例如Standard_D32s_v3。 |
| tier |
特定 SKU 的層級,例如 GeneralPurpose。 |
Network
伺服器的網路相關屬性
| 名稱 | 類型 | Description |
|---|---|---|
| delegatedSubnetResourceId |
string |
用來為伺服器設定 vnet 的委派子網資源標識碼。 |
| privateDnsZoneResourceId |
string |
私人 DNS 區域資源識別碼。 |
| publicNetworkAccess |
此伺服器是否允許公用網路存取。 當伺服器具有 VNet 整合時,值為 『Disabled』。 |
PatchStrategy
列舉以指出伺服器的修補程式策略
| 值 | Description |
|---|---|
| Regular | |
| VirtualCanary |
PrivateEndpoint
私人端點資源。
| 名稱 | 類型 | Description |
|---|---|---|
| id |
string |
私人端點的ARM標識碼。 |
PrivateEndpointConnection
私人端點聯機資源。
| 名稱 | 類型 | Description |
|---|---|---|
| id |
string (arm-id) |
資源的完整資源標識碼。 例如 “/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}” |
| name |
string |
資源的名稱 |
| properties.groupIds |
string[] |
私人端點資源的群組標識碼。 |
| properties.privateEndpoint |
私人端點資源。 |
|
| properties.privateLinkServiceConnectionState |
服務取用者與提供者之間連線狀態的相關信息集合。 |
|
| properties.provisioningState |
私人端點聯機資源的布建狀態。 |
|
| systemData |
包含 createdBy 和 modifiedBy 資訊的 Azure Resource Manager 中繼資料。 |
|
| type |
string |
資源的類型。 例如「Microsoft.Compute/virtualMachines」或「Microsoft.Storage/storageAccounts」 |
PrivateEndpointConnectionProvisioningState
目前的布建狀態。
| 值 | Description |
|---|---|
| Succeeded | |
| Creating | |
| Deleting | |
| Failed |
PrivateEndpointServiceConnectionStatus
私人端點連線狀態。
| 值 | Description |
|---|---|
| Pending | |
| Approved | |
| Rejected |
PrivateLinkServiceConnectionState
服務取用者與提供者之間連線狀態的相關信息集合。
| 名稱 | 類型 | Description |
|---|---|---|
| actionsRequired |
string |
訊息,指出服務提供者上的變更是否需要取用者的任何更新。 |
| description |
string |
核准/拒絕連線的原因。 |
| status |
指出服務擁有者是否已核准/拒絕/移除連線。 |
ReplicationRole
複寫角色。
| 值 | Description |
|---|---|
| None | |
| Source | |
| Replica |
Server
表示伺服器。
| 名稱 | 類型 | Description |
|---|---|---|
| id |
string (arm-id) |
資源的完整資源標識碼。 例如 “/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}” |
| identity |
伺服器的 Cmk 身分識別。 |
|
| location |
string |
資源所在的地理位置 |
| name |
string |
資源的名稱 |
| properties.administratorLogin |
string |
系統管理員的伺服器登入名稱。 只有在建立伺服器時才能指定 (而且是建立的必要專案)。 |
| properties.administratorLoginPassword |
string (password) |
系統管理員登入的密碼(建立伺服器所需的密碼)。 |
| properties.availabilityZone |
string |
伺服器的可用性區域資訊。 |
| properties.backup |
備份伺服器的相關屬性。 |
|
| properties.createMode |
建立新 MySQL 伺服器的模式。 |
|
| properties.dataEncryption |
CMK 的數據加密。 |
|
| properties.databasePort |
integer (int32) |
伺服器資料庫埠。 只能在建立伺服器時指定。 |
| properties.fullVersion |
string |
主要版本和實際引擎版本 |
| properties.fullyQualifiedDomainName |
string |
伺服器的完整功能變數名稱。 |
| properties.highAvailability |
伺服器的高可用性相關屬性。 |
|
| properties.importSourceProperties |
從記憶體匯入的來源屬性。 |
|
| properties.maintenancePolicy |
伺服器的維護原則。 |
|
| properties.maintenanceWindow |
伺服器的維護時間範圍。 已知問題:無法在伺服器建立期間設定,或在伺服器更新期間以其他屬性更新;必須個別更新。 |
|
| properties.network |
伺服器的網路相關屬性。 |
|
| properties.privateEndpointConnections |
Server 的 PrivateEndpointConnections 相關屬性。 |
|
| properties.replicaCapacity |
integer (int32) minimum: 0 |
主伺服器可以擁有的複本數目上限。 |
| properties.replicationRole |
複寫角色。 |
|
| properties.restorePointInTime |
string (date-time) |
還原點建立時間(ISO8601格式),指定要還原的時間。 |
| properties.sourceServerResourceId |
string |
來源 MySQL 伺服器識別碼。 |
| properties.state |
伺服器的狀態。 |
|
| properties.storage |
伺服器的記憶體相關屬性。 |
|
| properties.version |
MySQL 的主要版本。 8.0.21 代表 MySQL 8.0、5.7.44 代表 MySQL 5.7 |
|
| sku |
伺服器的 SKU(定價層)。 |
|
| systemData |
包含 createdBy 和 modifiedBy 資訊的 Azure Resource Manager 中繼資料。 |
|
| tags |
object |
資源標籤。 |
| type |
string |
資源的類型。 例如「Microsoft.Compute/virtualMachines」或「Microsoft.Storage/storageAccounts」 |
ServerSkuTier
特定 SKU 的層級,例如 GeneralPurpose。
| 值 | Description |
|---|---|
| Burstable | |
| GeneralPurpose | |
| MemoryOptimized |
ServerState
伺服器的狀態。
| 值 | Description |
|---|---|
| Ready | |
| Dropping | |
| Disabled | |
| Starting | |
| Stopping | |
| Stopped | |
| Updating |
ServerVersion
伺服器的主要版本。 8.0.21 代表 MySQL 8.0、5.7.44 代表 MySQL 5.7
| 值 | Description |
|---|---|
| 5.7 | |
| 8.0.21 |
Storage
伺服器的記憶體配置檔屬性
| 名稱 | 類型 | 預設值 | Description |
|---|---|---|---|
| autoGrow | Disabled |
啟用記憶體自動成長。 |
|
| autoIoScaling | Enabled |
啟用 IO 自動調整。 |
|
| iops |
integer (int32) |
伺服器的記憶體 IOPS。 |
|
| logOnDisk | Disabled |
啟用登入磁碟。 |
|
| storageRedundancy | LocalRedundancy |
伺服器記憶體的備援類型。 參數用於伺服器建立。 |
|
| storageSizeGB |
integer (int32) |
伺服器允許的記憶體大小上限。 |
|
| storageSku |
string |
伺服器記憶體的 SKU 名稱。 |
StorageRedundancyEnum
伺服器記憶體的備援類型。 參數用於伺服器建立。
| 值 | Description |
|---|---|
| LocalRedundancy | |
| ZoneRedundancy |
systemData
與建立和上次修改資源相關的元數據。
| 名稱 | 類型 | Description |
|---|---|---|
| createdAt |
string (date-time) |
資源建立的時間戳(UTC)。 |
| createdBy |
string |
建立資源的身分識別。 |
| createdByType |
建立資源的身分識別類型。 |
|
| lastModifiedAt |
string (date-time) |
上次修改的資源時間戳 (UTC) |
| lastModifiedBy |
string |
上次修改資源的身分識別。 |
| lastModifiedByType |
上次修改資源的身分識別類型。 |
UserAssignedIdentity
使用者指派身分識別的元數據。
| 名稱 | 類型 | Description |
|---|---|---|
| clientId |
string |
使用者指派身分識別的用戶端識別碼 |
| principalId |
string |
使用者指派身分識別的主體識別碼 |