Bicep deployment of a Azure SqlServer takes along time and eventually times out

Bart Huls 0 Reputation points
2023-09-04T11:05:17.1533333+00:00

I'm using a bicep script to deploy our sql databases:
It takes a long time and eventually it times out.

resource sqlServerResource 'Microsoft.Sql/servers@2022-05-01-preview' = {
  name: sqlserverServerName
  location: location
  properties: {
    version: '12.0'
    administratorLogin: xxxxx
    administratorLoginPassword: xxxxx
    administrators: {
      administratorType: 'ActiveDirectory'  
      principalType: 'Group'  
      login: 'xxxx' 
      sid: 'xxxx'
      tenantId: subscription().tenantId
      azureADOnlyAuthentication: false      
    }   
  }
}


resource databaseResource 'Microsoft.Sql/servers/databases@2022-05-01-preview' = {
  parent: sqlServerResource
  name: sqlserverDbName
  location: location
  sku: {
    name: 'Standard'
    tier: 'Standard'
    capacity: 20
  }

}

It takes more then 30 minutes....
Can someone explain to me why this is?

Regards,
Bart Huls

Azure SQL Database
{count} votes

2 answers

Sort by: Most helpful
  1. ShaktiSingh-MSFT 15,056 Reputation points
    2023-09-04T15:33:37.1566667+00:00

    Hi Bart Huls •,

    Welcome to Microsoft Q&A forum.

    As I understand, you are getting error while using a bicep script to deploy our sql databases timed out.

    Please refer to the similar issued thread here and let us know if the solution helped:

    https://learn.microsoft.com/en-us/answers/questions/1298800/sql-provisioning-on-azure-with-bicep-fails-with-ti

    SQL provisioning on Azure with Bicep fails with timeout error - The resource write operation failed to complete successfully

    Thanks

    0 comments No comments

  2. ShaktiSingh-MSFT 15,056 Reputation points
    2023-09-13T05:18:18.14+00:00

    Hi Bart Huls •,

    We haven't heard from you.

    Bicep is a domain-specific language (DSL) that uses declarative syntax to deploy Azure resources. It provides concise syntax, reliable type safety, and support for code reuse.

    Review your bicep file as illustrated here: https://learn.microsoft.com/en-us/azure/azure-sql/database/single-database-create-bicep-quickstart?view=azuresql&tabs=CLI

    as when I tried your Bicep, it shows below errors:

    User's image

    Please share full bicep details with hidden PII data so that we can reproduce the scenario.

    And check if all needed parameters are defined correctly.

    Try and let us know if this helped.

    Thanks

    0 comments No comments

Your answer

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