排查在 Azure 中重新启动现有 Windows VM 或调整其大小时遇到的部署问题Troubleshoot deployment issues with restarting or resizing an existing Windows VM in Azure

尝试启动已停止的 Azure 虚拟机 (VM),或调整现有 Azure VM 的大小时,经常遇到的错误是分配失败。When you try to start a stopped Azure Virtual Machine (VM), or resize an existing Azure VM, the common error you encounter is an allocation failure. 当群集或区域没有可用的资源或无法支持所请求的 VM 大小时,将发生此错误。This error results when the cluster or region either does not have resources available or cannot support the requested VM size.

如果本文未解决你的 Azure 问题,请访问 MSDN 和 CSDN 上的 Azure 论坛。If your Azure issue is not addressed in this article, visit the Azure forums on MSDN and CSDN. 可以在这些论坛上发布问题。You can post your issue in these forums. 还可提交 Azure 支持请求。You also can submit an Azure support request. 若要提交支持请求,请在 Azure 支持页上提交。To submit a support request, on the Azure support page.

收集活动日志Collect activity logs

若要开始故障排除,请收集活动日志,以识别与问题相关的错误。To start troubleshooting, collect the activity logs to identify the error associated with the issue. 以下链接包含有关过程的详细信息:The following links contain detailed information on the process:

查看部署操作View deployment operations

通过查看活动日志管理 Azure 资源View activity logs to manage Azure resources

问题:启动已停止的 VM 时发生错误Issue: Error when starting a stopped VM

尝试启动已停止的 VM,但出现分配失败。You try to start a stopped VM but get an allocation failure.

原因Cause

必须在托管云服务的原始群集上尝试发出启动已停止 VM 的请求。The request to start the stopped VM has to be attempted at the original cluster that hosts the cloud service. 但是,群集没有足够的空间可完成该请求。However, the cluster does not have free space available to fulfill the request.

解决方法Resolution

  • 停止可用性集中的所有 VM 并重新启动每个 VM。Stop all the VMs in the availability set, and then restart each VM.

    1. 单击“资源组” > 资源组 > “资源” > 可用性集 > “虚拟机” > 虚拟机 > “停止”。Click Resource groups > your resource group > Resources > your availability set > Virtual Machines > your virtual machine > Stop.
    2. 所有 VM 停止后,选择每个已停止的 VM 并单击“启动”。After all the VMs stop, select each of the stopped VMs and click Start.
  • 稍后重试重新启动请求。Retry the restart request at a later time.

问题:调整现有 VM 的大小时发生错误Issue: Error when resizing an existing VM

尝试调整现有 VM 的大小,但出现分配失败。You try to resize an existing VM but get an allocation failure.

原因Cause

必须在托管云服务的原始群集上尝试发出调整 VM 大小的请求。The request to resize the VM has to be attempted at the original cluster that hosts the cloud service. 但是,群集不支持请求的 VM 大小。However, the cluster does not support the requested VM size.

解决方法Resolution

  • 以更小的 VM 大小重试请求。Retry the request using a smaller VM size.

  • 如果无法更改请求的 VM 大小:If the size of the requested VM cannot be changed:

    1. 停止可用性集中的所有 VM。Stop all the VMs in the availability set.

      • 单击“资源组” > 资源组 > “资源” > 可用性集 > “虚拟机” > 虚拟机 > “停止”。Click Resource groups > your resource group > Resources > your availability set > Virtual Machines > your virtual machine > Stop.
    2. 所有 VM 停止后,将所需的 VM 调整到更大的大小。After all the VMs stop, resize the desired VM to a larger size.

    3. 选择已调整大小的 VM,单击“启动”,并启动每个已停止的 VM。 Select the resized VM and click Start, and then start each of the stopped VMs.

后续步骤Next steps

如果在 Azure 中创建新的 Windows VM 时遇到问题,请参阅排查在 Azure 中新建 Windows 虚拟机时遇到的部署问题If you encounter issues when you create a new Windows VM in Azure, see Troubleshoot deployment issues with creating a new Windows virtual machine in Azure.