Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-59824

Ignore timeout while provisioning

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • _unsorted
    • None

      We've set up a new custom image which takes a lot of time provisioning (40+ minutes).

      I've set the deployment timeout to 5000 seconds but after around 40 minutes the VM will get deleted cause of this exception:

       

      AzureVMCloud: createProvisionedAgent: Deployment win10pp16-1017121639027 not yet finished (Running): Microsoft.Compute/virtualMachines:win10pp-725b70 - waited 2,310 seconds
      Oct 17, 2019 12:56:06 PM SEVERE com.microsoft.azure.vmagent.AzureVMCloud$2 callFailure creating provisioned agent 'win10pp-725b70'
      com.microsoft.azure.vmagent.exceptions.AzureCloudException: AzureVMCloud: createProvisionedAgent: Deployment Failed: Microsoft.Compute/virtualMachines:win10pp-725b70 - Conflict - {status=Failed, error={code=ResourceDeploymentFailure, message=The resource operation completed with terminal provisioning state 'Failed'., details=[{code=OSProvisioningTimedOut, message=OS Provisioning for VM 'win10pp-725b70' did not finish in the allotted time. The VM may still finish provisioning successfully. Please check provisioning state later. Also, make sure the image has been properly prepared (generalized).
       * Instructions for Windows: https://azure.microsoft.com/documentation/articles/virtual-machines-windows-upload-image/ 
       * Instructions for Linux: https://azure.microsoft.com/documentation/articles/virtual-machines-linux-capture-image/ }]}}
      	at com.microsoft.azure.vmagent.exceptions.AzureCloudException.create(AzureCloudException.java:37)
      	at com.microsoft.azure.vmagent.AzureVMCloud.createProvisionedAgent(AzureVMCloud.java:584)
      	at com.microsoft.azure.vmagent.AzureVMCloud$2.call(AzureVMCloud.java:830)
      	at com.microsoft.azure.vmagent.AzureVMCloud$2.call(AzureVMCloud.java:808)
      	at jenkins.util.ContextResettingExecutorService$2.call(ContextResettingExecutorService.java:46)
      	at jenkins.security.ImpersonatingExecutorService$2.call(ImpersonatingExecutorService.java:71)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at java.lang.Thread.run(Unknown Source)
      
      
      

      Is there a way to ignore this exception? The VM actually works after waiting another 10-20 minutes (it then switches from status creating to running).

      Right now it will delete the VM and start creating a new one which also runs into the timout.

            jieshe Jie Shen
            orangepie Mike K
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: