Share via

cannot provision flexible postgres - internal server error

Anonymous
2023-06-01T07:54:38.26+00:00

Hi,

I'm trying to provision a flexible postgres instance. But while provisioning I get an internal server error:

" Resource Group Name: "dev-gen-rg-westeu" Flexible Server Name: "dev-gen-fx-psql-westeu"): polling after Create: Code="InternalServerError" Message="An unexpected error occured while processing the request. Tracking ID: 'bd319610-ba5f-4fa4-88a5-08d98720d58a'"

with azurerm_postgresql_flexible_server.flexible_psql, on storage_psql_flexible_server.tf line 37, in resource "azurerm_postgresql_flexible_server" "flexible_psql": 37: resource "azurerm_postgresql_flexible_server" "flexible_psql" {"

The resource definition is here:

resource "azurerm_postgresql_flexible_server" "flexible_psql" {
  name                              = local.flexible_psql_name
  resource_group_name               = azurerm_resource_group.rg.name
  location                          = azurerm_resource_group.rg.location
  delegated_subnet_id               = azurerm_subnet.flexible_psql_subnet.id
  private_dns_zone_id               = azurerm_private_dns_zone.flexible_private_dns.id
  sku_name                          = "GP_Standard_D2ds_v4"
  version                           = "11"
  administrator_login               = var.psql_credential.admin_name
  administrator_password		    = var.psql_credential.admin_pass
  geo_redundant_backup_enabled      = false
  backup_retention_days             = 7
  storage_mb                        = 131072 #524288
  zone                   			= "1"

  depends_on = [azurerm_private_dns_zone_virtual_network_link.flexible_dns_link]

  lifecycle {
    prevent_destroy = true
  }
}

How can i solve this?

Azure Database for PostgreSQL
0 comments No comments

Answer accepted by question author

RahulRandive 10,506 Reputation points
2023-06-01T14:05:47+00:00

Hi @Anonymous

I understand that you are trying to deploy Postgres flexible server and getting internal server error

Maybe your region doesn’t support “zone = 1” for “azurerm_postgresql_flexible_server” Could you change to another available zone to see if the issue still exists?

Please use either Zone 2 or 3 and it will go through it.

Thank you!

Was this answer helpful?

1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.