Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Windows Azure Virtual Machine deleted after spending limit reached - How can I get it back?

As you can tell from the title, I set up a virtual machine on Azure and installed a website and database that my company is hosting for a client. The spending limit was not lifted, and after it was reached my VM was deleted.

Since that time I have lifted the spending limit, but I have no idea how to get the VM back, or if that is possible at all. What are the steps I need to take in order to get back to where it was? Is the database that was on this server gone for good? I spent hours getting this server up to date with updates and Web Platform Installer software. This would be rather cruel if everything is now lost.

like image 963
MattSavage Avatar asked Oct 08 '12 23:10

MattSavage


2 Answers

I had the same experience. Our Azure Virtual machine was gone, and I got really scared when it was also missing from the management portal. I solved it like this.

  1. Remove the spending limit on the credit card from the Azure account portal.
  2. Delete the cloudservice that had the same name as the VM. The cloud service was only an empty container now that the VM was gone.
  3. It is easy to restore the missing VM by creating a new Virtual Machine. Choose to create a new VM from Gallery, and under the Gallery you can find your missing machines harddisk under "My disks".
  4. Wait while the machine is restored, and then start it.
  5. Now you have to manually recreate all network endpoints. That was a pain as I had quite a few different streaming servers installed.

I wish that Azure only stopped an virtual machine instead of silently removing it when the customer fails to pay. Especially because it is quite hard to understand which services are free, which services are free trials and which services that you must pay for.

like image 22
Jacob Hamacher Avatar answered Sep 26 '22 10:09

Jacob Hamacher


Are you sure the VM was actually deleted, or was the deployment deleted? Check in the portal under the Virtual Machines tab. Look under the Disks section and see if you have a disk there that represents the server that was running.

If so, you should be able to create a new Virtual Machine instance by using the New button at the bottom of the portal. Click on the New button and select Compute > Virtual Machine > From Gallery. Then click on the My Disks under the popup screen. This will let you select the disk that represents the OS disk from your server.

You may also want to check to see if the Cloud Service container that was running the server was also deleted. When you create a Virtual Machine a Cloud service is created to act like a container for that machine instance. You can also add additional machines to that same container. Take a look under Cloud Services in the portal and see if one is there named like what you had setup for the virtual machine. If so, then you'll either have to delete this one so you can reuse the name, or you can user the PowerShell cmdlets to start the virtual machine and put it into the already existing cloud services container.

like image 75
MikeWo Avatar answered Sep 24 '22 10:09

MikeWo