Azure VM Failed not start stay on Updating mode - azure

I use azure vm, when vm is restart then failed to start vm error and stay on Updating mode, so I don't use azure recovery services.

Probably more of a server fault question.
Couple of things you can try:
Completely stop the VM to stopped(deallocated) status, then boot it backup, if you have problem stop it from portal, use powershell cmdlet
Re-size the VM, normally would move it to another host and can jump off the problematic host
Delete the VM retain disks, create another VM from the disk.
There is also a good chance all above would fail. If you have a RTO, you might want to start preparing failover/recreate the machine in parallel.

If someone is still experiencing the stuck in the UPDATING status, it's probably your VM's Disk ran out of space, what I did is I increased the size and it boot fine.

Related

Factory reset Windows Server 2016 on Azure

I installed a few beta version of some apps and now the functionality of the Windows is broken.
Is there any way I can reset the windows to it's initial state from the portal or I have to remove it and create a new one?
If you have not backup this VM or take a snapshot of this VM, we should re-create a new VM.
As mentioned by Jason, if a backup or a snapshot was taken, you could use them to recover the VM.
You have mentioned, ‘now the functionality of the Windows is broken’, unsure if you are facing some boot issue or something else. Please do let me know if feasible, you could look at fixing the underlying issue. Or just recreate the problematic VM and not the entire Resource Group itself.
I would like to highlight the process of recovering the OS below:
Delete the VM encountering issues, keeping the virtual hard disks.
Attach and mount the virtual hard disk to another Windows VM for troubleshooting purposes.
Connect to the troubleshooting VM. Edit files or run any tools to fix issues on the original virtual hard disk.
Unmount and detach the virtual hard disk from the troubleshooting VM.
Create a VM using the original virtual hard disk.
Refer the document for more details on this process.

Start generalized azure VM

I am working on an azure deployment. I am using some templates from github that creates a certain number of VM's based on a 'master image', puts them behind a load balancer, and allows access to them through RDP and ports.
Now, all this is working great. I build my image, then I run sysprep and generalize it, shut it down, and spin up 40 copies.
The issue I am running into is what do I do if I want to update the 'master image'?
It won't let me boot it up, because it says it is generalized. And I am having a hard time setting up a new vm and attaching the OS disk "not sure if this is the right way"
Does anyone have any suggestions? I am coming from a VMware VDI environment, where I would just boot up the master, make changes, shut down, and snapshot and redeploy.
Also I am using the new Azure interface, which I believe is called AzureRM.
Error message: Operation Start VM is not allowed on VM xxx since the VM is generalized.
Like versioning, you have to create a new VM from the image made before, and then repeat the process again after your changes.
Well, its not pretty, but it should work:
Spin up a fresh copy. make your changes, then preform the sysprep / oobe process again, finally, generalize & capture.

Is it possible to Capture running machine on Azure or it is recommended to shutdown before?

I have an Ubuntu 14 VM on Azure to host my developed web sites. (I do not think the OS matters in the point of view the question, but never know)
I've discovered the relatively new Capture button, so for the storage price of a disk size I regularly save a "snapshot" via the Capture function (I am not preparing the image for provisioning, I mean not checking the "I have run 'waagent -deprovision' on the virtual machine" checkbox). Be aware quickly becomes pretty addictive.
The result is an image what I can use when creating new machines, its there in My Images in the wizard. This can function as a backup/rollback worflow. If I delete the VM and create a new from one of resulting image of the previously captured "snapshots". (again, no provisioning will take place)
It is possible to initiate the Capture operation on a running VM. It is not clear for me, if the result will be an image what is a template for a new VM, and that VM will start up and boot, in what state the filesystem etc will be?
Is not it a similar state than sudden power lost? If yes, then it is strongly recommended to always shutdown the VM before capturing, however this such a pain and productivity killer, so no one (including me) wants to do unless it is mandatory.
Accidentally I've switched to the new Azure portal and there the Capture UI says:
Capturing a virtual machine while it's running isn't recommended.

seeking example of azure Linux VM deprovisioning itself (via helper VM)

I would not imagine that a VM could deprovision itself fully (but that would be a nice feature), but must start a helper VM to do that. I am seeking an example of such for a Linux VM. I would actually like an example where a VM could be completely cleaned up after, deprovision, delete, delete disks (boot included), no trace left, no storage consumed, nada.
If you are running from Linux you can use the Azure CLI which provides the functionality you need.
If you run a force delete on a VM with the option to delete the underlying disk, the command will be registered with Azure before the operation starts, therefore it is perfectly possible to completely delete a running VM from within that VM.
Since you're deleting the entire stack, there's no need to gracefully shutdown beforehand (which would be more challenging - though not impossible) You can just hit the delete button and let Azure figure the rest out.

What happens to Azure virtual machines software, if vm size is updated?

I use MS azure virtual machine. IIS running, hosting different web sites. What happens ,when I update vm from extra small to small ? Should I take a backup or nothing is required?There are some IIS bindings, should I move those settings ?
I think it is similar to gave more memory in vmware machine . But since it is vital for us, I am asking this question .
The VM will be gracefully shutdown and brought back up (most likely on a completely different VM host), so you will see some downtime as that transition occurs. The actual data for your machine is stored in BLOB storage, not on the VM itself, so you don't specifically need to worry about a back up because you are making this change. That said, if this is a production machine you need to be thinking about backups anyway.

Resources