Conflict during deployment CustomScriptExtension runs into a timeout

Christopher Hähnel 21 Reputation points
2020-09-16T19:33:32.983+00:00

Hello Community, I have tried to deploy the Azure Deployment package from https://learn.microsoft.com/de-de/learn/modules/migrate-sql-server-relational-data/2-exercise-environment-setup to my account. Unfortunately this failed. It is only the component of the CustomScriptExtension. Here is the error in pure form:

{  
  "code": "DeploymentFailed",  
  "message": "Bei der Ressourcenbereitstellung ist mindestens ein Fehler aufgetreten. Listen Sie die Bereitstellungsvorgänge auf, um Details anzuzeigen. Weitere Informationen zur Verwendung finden Sie unter https://aka.ms/DeployOperations.",  
  "details": [  
    {  
      "code": "Conflict",  
      "message": "{\r\n  \"status\": \"Failed\",\r\n  \"error\": {\r\n    \"code\": \"ResourceDeploymentFailure\",\r\n    \"message\": \"Der Ressourcenvorgang wurde mit Bereitstellungsendzustand \\\"Failed\\\" abgeschlossen.\",\r\n    \"details\": [\r\n      {\r\n        \"code\": \"VMExtensionProvisioningTimeout\",\r\n        \"message\": \"Timeout bei der Bereitstellung der VM-Erweiterung \\\"CustomScriptExtension\\\". Die Bereitstellung der Erweiterung hat zu lange gedauert. Die Erweiterung hat keine Fehlermeldung zurückgegeben. Weitere Informationen zur Problembehandlung finden Sie unter https://aka.ms/VMExtensionCSEWindowsTroubleshoot.\"\r\n      }\r\n    ]\r\n  }\r\n}"  
    }  
  ]  
}  
Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,130 questions
0 comments No comments
{count} votes

Accepted answer
  1. Andreas Baumgarten 96,441 Reputation points MVP
    2020-09-16T21:25:09.12+00:00

    It seems something is not working properly with the Custom Script Extension in the Deployment Template.

    I tried to deploy as well and these are my findings so far:

    During the deployment a PowerShell script is executed. You can find more details here

    25381-templatescripturi.png

    If you click on the link the PowerShell script will open

    25382-psscript.png

    The error message you can see here

    25217-errormessage.png

    It seems something is wrong with this line "Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force | Out-Null;"
    No Nuget Package provider is found that mets the criteria of the MinimumVersion (my guess)

    After a certain time the deployment timeout error message will pop up.

    Maybe this is helpful.

    Regards

    Andreas Baumgarten

    (Please don't forget to Accept as answer if the reply is helpful)

    2 people found this answer helpful.
    0 comments No comments

3 additional answers

Sort by: Most helpful
  1. Jason 6 Reputation points
    2020-10-05T18:44:07.517+00:00

    Thanks for reporting this issue. It looks like the PowerShell gallery updated to TLS1.2. The script for this Learn module has been updated to use TLS 1.2.

    https://devblogs.microsoft.com/powershell/powershell-gallery-tls-support/

    1 person found this answer helpful.
    0 comments No comments

  2. Christopher Hähnel 21 Reputation points
    2020-09-17T06:35:44.41+00:00

    Thank you @Andreas Baumgarten for the quick reply. Looks like you have identified the problem. I will pass it on to MS Learn. Thanks again. :)

    EDIT: I asked to fix this in the related Git-Repo.

    0 comments No comments

  3. FlorisZ 1 Reputation point
    2020-10-06T07:56:50.537+00:00

    Fix confirmed. Thank you
    30269-deployment-finished.jpg

    0 comments No comments