bicep
bicep copied to clipboard
InternalServerError - Long running operation failed with status 'Failed'. Additional Info:'Encountered internal server error while processing the deployment what-if request
Bicep version Bicep CLI version 0.7.4
Describe the bug Hi, I have a problem with multiple module calls with context switch (Subscription, RG) within a main.bicep. In the main bicep I try to create a spoke and depending on the input params to either peer to the vWAN hub or unmanaged hub (VNET). In addition, each spoke should be peered to an Azure Bastion VNET.
My issue always occurs with the SECOND module call with context switch (Subscription, RG). If I comment out all modules with context switch except one (no matter which one) the deployment works.
Debug Output of my command:
New-AzDeployment `
-Location $param.p_location `
-Name $deploymentName `
-TemplateFile $templateFilePath `
-TemplateParameterObject $templateParams `
-Confirm `
-Verbose `
-Debug
DEBUG: ============================ HTTP RESPONSE ============================
Status Code:
OK
Headers:
Pragma : no-cache
x-ms-ratelimit-remaining-subscription-reads: 11999
x-ms-request-id : 5470c854-c0b3-478b-9cc9-46788880759c
x-ms-correlation-request-id : 5470c854-c0b3-478b-9cc9-46788880759c
x-ms-routing-request-id : GERMANYWESTCENTRAL:20220620T101925Z:5470c854-c0b3-478b-9cc9-46788880759c
Strict-Transport-Security : max-age=31536000; includeSubDomains
X-Content-Type-Options : nosniff
Cache-Control : no-cache
Date : Mon, 20 Jun 2022 10:19:24 GMT
Body:
{
"status": "Failed",
"error": {
"code": "InternalServerError",
"message": "Encountered internal server error while processing the deployment what-if request. Diagnostic information: timestamp '20220620T101911Z', scope '/subscriptions/c3b14395-a806-4041-a8c0-fe0149f6ea20', tracking id 'e87e37bb-b43a-429a-b5fb-80a9d939df1e', request correlation id
'02f6c865-3fcc-4da5-82dd-5a33b19a5952'."
}
}
To Reproduce
As soon as I comment out point 1 or 2 from my main.bicep, so that only one module with context switch is called, it works. Both modules at the same time throw the error.
I have no clue what's wrong here, but for me it looks like a bug. Thank you all in advance for your help!
Best Daniel
Can you provide a correlation ID for this issue to help us investigate?
Hi @alex-frankel,
thanks for your answer! Sure, here are two correlation IDs of failed deployments:
- 232e2e3a-1455-4e20-b84c-520630a0503b
- 02f6c865-3fcc-4da5-82dd-5a33b19a5952
Thank you!
The fix was deployed.