0

我想为基于位置的服务需求创建 PostgreSQL。接下来我将安装 GIS 扩展。

我已经手动创建了 Azure Database for PostgreSQL 灵活服务器来决定正确的配置。"sku": {"name": "Standard_B1ms","tier": "Burstable"} 我想创建单服务器,但由于某种原因它在欧洲不可用。我认为缺少 Burstable 对初始 POC 有好处,但通用性也很好。

现在尝试用二头肌创建 PostgreSQL。但是我很难设置有效的服务器。首先 Burstable 不可用。接下来我无法设置有效的 sku 名称。

az 部署组创建:

{"status":"Failed","error":{"code":"DeploymentFailed","message":"At least one resource 
deployment operation failed. Please list deployment operations for details. Please see 
https://aka.ms/DeployOperations for usage details.","details": 
[{"code":"BadRequest","message":"{\r\n  \"error\": {\r\n    \"code\": 
\"InvalidEditionSloCombination\",\r\n    \"message\": \"The edition 
GeneralPurpose does not support the service objective Standard_D2s_v3\"\r\n  }\r\n}"}]}}

主二头肌:

resource symbolicname 'Microsoft.DBforPostgreSQL/servers@2017-12-01' = {
  name: 'my-postgresql-dev'
  location: 'West Europe'
  tags: {
    tagName1: 'tagValue1'
    tagName2: 'tagValue2'
  }
  sku: {
    name: 'Standard_D2s_v3' 
    tier: 'GeneralPurpose'
  }
  identity: {
    type: 'SystemAssigned'
  }
  properties: {
    administratorLogin: 'sqladmin'
    administratorLoginPassword: 'asfar43efw!sdf'
    storageProfile: {
      backupRetentionDays: 7
      geoRedundantBackup: 'Disabled'
      storageMB: 32000
    }
    version: '11'
    createMode: 'Default'
    // For remaining properties, see ServerPropertiesForCreate objects
  }
}
4

1 回答 1

0

您收到的错误与 sku 名称有关:

The edition GeneralPurpose does not support the service objective Standard_D2s_v3

查看文档,sku 名称具有特定的命名约定:

sku 的名称,通常是层 + 家族 + 核心,例如 B_Gen4_1、GP_Gen5_8。

在您的情况下,出于一般目的,它将是 GP_GEN5_{核心数}。

于 2021-12-12T07:00:17.607 回答