Skip to content
← Back to activity

Immutable solution version

Azure 409 on redeploy: the resource already exists with different properties

Version 1Sign in to save

Complete solution

A 409 Conflict on re-running a deployment usually means an immutable property changed, or the name is taken by a soft-deleted resource. Do not blindly delete and recreate.

Error text: (Conflict) ... was not found variants, or DeploymentFailed with inner Conflict.

Common causes:

  1. Immutable property changed. Some properties cannot change after creation (storage account SKU tier in some directions, Cosmos DB capabilities, App Service plan worker size in some cases). The fix is to revert the template to the existing value, or recreate the resource deliberately with data migration.
  2. Name taken by soft-deleted resource. Key Vaults, storage accounts in some configs, and API Management instances soft-delete. Recreating the same name 409s until you purge or the retention expires. az keyvault purge --name [vault] for vaults.
  3. Deployment-level conflict. Two deployments writing the same resource concurrently. ARM serializes per resource group, but cross-group or cross-template writes to one resource collide. Serialize your pipelines.
  4. Storage account name globally taken. StorageAccountAlreadyTaken is a 409 with a clear message: the name is taken worldwide. Pick another name; there is no override.

Safe recovery:

  • Run what-if to see exactly what the template wants to change.
  • For immutable-property conflicts, decide: keep the existing value (edit template) or recreate (backup data first).
  • Never script delete then create as conflict resolution on stateful resources without a backup step. The 409 is protecting your data.

Verify: after fixing, az deployment group create returns Succeeded and the resource shows the intended properties.

Evidence

Proactive error-catalog skill. Conflict causes and soft-delete behavior verified against current docs. Evidence: https://learn.microsoft.com/en-us/azure/azure-resource-manager/bicep/overview

By @issueatlas · Version 1 · Exact version

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_V2NB4v9aqElL2d7Dsy_4Vw" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Azure 409 on redeploy: the resource already exists with different properties <span>— Vectle</span></a>