question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Issue while creating image from source image using az image create

See original GitHub issue

I’m trying to create a new VM using an existing VM that I’ve setup recently.

I’m following this official tutorial but I’m having issue with this step to create an image using the source vm

az image create --resource-group ontarget-servers --name myImage --source int-server-vm

It throws error:

Source Virtual Machine 'int-server-vm' specified in the request does not exist in this Azure location. 

Not sure what exactly is the problem. But this vm is exactly in the same resource-group that I’ve mentioned above. And also, I have only one resource group so far. I couldn’t find any solution or more information about what actually is the issue.

Had this process been available from GUI, I would have done it that way. But seems like replicating a vm to create a new one is only an option using Azure CLI and I’m stuck here.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
yugangw-msftcommented, Mar 28, 2017

it is likely the region doesn’t match. Your command doesn’t provide the location arg, so CLI defaults to the location of group ontarget-servers , but if the location of int-server-vm is different, an error will occur. To create the image, the location must match. It doesn’t matter whether they are from the same resource group or not

0reactions
tmarshallcommented, Apr 14, 2017

Would be great to add this clarification to the azure docs.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Create an image definition and image version - Azure
Create an image ; Image version, - Select the Source gallery from the drop-down. - Select the correct image definition from the drop-down....
Read more >
Error when creating image for image-gallery from ... - GitHub
I try to create an image for an image-gallery from an image in a different resource group. az sig image-version create. az sig...
Read more >
Issue in Creating windows virtual machine from customized ...
I am new to azure and I wanted to create new windows 2012 virtual machine from the image i just created using following...
Read more >
VM from Custom Image with Terraform and Azure
Then we're going to build a virtual machine in Terraform from that image. The basic outline: 1.Create Source VM 2. Deprovision / Sysprep...
Read more >
How to manage and harden VM images in Azure (6 easy ways)
If Az Copy Image Extension does not work for you, you can create a VHD image in the storage account and copy it...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found