I have created first VM from Azure portal interface and it works good. I tried to deploy second VM using ARM template that is available from first VM. And I can't do it quickly. Primarily, I have to solve task with some dependency loops because I got message 'Circular dependency detected on resource: '/subscriptions/xxxxxxxxx/resourceGroups/MOD03VDSC/providers/Microsoft.Network/networkInterfaces/autoconfigvm7312'. It this a bag or feature? How can I quickly redeploy VM without analyze every time the dependencies?

  • Can you provide the ARM template? Usually, a circular dependency is because you have a resource that is dependant on another resource, that is its self dependant on the first.
    – Sam Cogan
    May 21, 2018 at 8:20

1 Answer 1


It’s not a bug or feather, it’s an error of your template.

For example

if A is dependent on B, and B is also dependent on A, then they make a “Circular dependency” and they cannot continue to work.


You should check the setting “dependsOn” of Network Interface in template. And then find the setting of dependent and check if the resource is also dependent on the Network Interface. If it is, that is the error “Circular dependency”.

You can analyses the resource dependency and remove in one side. I advise you check the whole template to ensure your template is OK.

  • The template is generated automatically by Azure when I deploy any VM through portal Azure. Why I have to analyze template that was automatically made for "Circular dependency" ? May be Azure ARM should generate template without this false loop?
    – Serg ОС
    May 22, 2018 at 9:22
  • The template is created after the deployment, not before. So some dependents will not be necessary before your deployment. I suggest you take a try with the solution.
    – Charles Xu
    May 22, 2018 at 9:46
  • If you finish your template that deploy the vm with the answer?
    – Charles Xu
    May 28, 2018 at 5:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.