Szerkesztés

Megosztás a következőn keresztül:


Redeploy Linux virtual machine to new Azure node

Applies to: ✔️ Linux VMs

If you face difficulties troubleshooting SSH or application access to a Linux virtual machine (VM) in Azure, redeploying the VM may help. When you redeploy a VM, it moves the VM to a new node within the Azure infrastructure and then powers it back on. All your configuration options and associated resources are retained. This article shows you how to redeploy a VM using Azure CLI or the Azure portal.

Warning

After you redeploy a VM, all the data that you saved on the temporary disk and Ephemeral disk is lost. The dynamic IP addresses associated with virtual network interface are updated.

Use the Azure CLI

Install the latest Azure CLI and log in to your Azure account using az login.

Redeploy your VM with az vm redeploy. The following example redeploys the VM named myVM in the resource group named myResourceGroup:

az vm redeploy --resource-group myResourceGroup --name myVM 

Use the Azure portal

  1. Go to the Azure portal, select the VM you wish to redeploy.
  2. In the Help section, select Redeploy + reapply, and then select Redeploy to migrate it to a new Azure host.

The image shows the redeploy and reapply option.

Next steps

If you are having issues connecting to your VM, you can find specific help on troubleshooting SSH connections or detailed SSH troubleshooting steps. If you cannot access an application running on your VM, you can also read application troubleshooting issues.

Contact us for help

If you have questions or need help, create a support request, or ask Azure community support. You can also submit product feedback to Azure feedback community.