你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

使用 Azure 开发测试实验室中的自动启动自动启动实验室 VM

本文介绍如何为 Azure 开发测试实验室虚拟机(VM)配置和应用自动启动策略。 自动启动会在指定时间和天数自动启动实验室 VM。

若要实现自动启动,请先为实验室配置自动启动策略。 然后,可以为单个实验室 VM 启用策略。 要求单个 VM 启用自动启动有助于防止不必要的启动可能会增加成本。

还可以为实验室 VM 配置自动分机策略。 有关详细信息,请参阅 在开发测试实验室中为实验室 VM 配置自动关机

先决条件

为实验室配置自动启动

若要为实验室配置自动启动策略,请完成这些步骤。 After you configure the policy, enable autostart for each VM that you want to start automatically.

  1. On your lab Overview page, select Configuration and policies under Settings in the left navigation.

    显示左侧导航菜单中选择“配置”和“策略”的屏幕截图。

  2. “配置和策略”页上,选择左侧导航中的“计划”下的“自动启动”。

  3. Select Yes for Allow auto-start.

    “计划”下的“自动启动”选项的屏幕截图。

  4. Enter a Scheduled start time, select a Time zone, and select the checkboxes next to the Days of the week that you want to add to the schedule.

  5. Select Save.

    自动启动计划设置的屏幕截图。

将 VM 添加到自动启动计划

配置自动启动策略后,请为要自动启动的每个 VM 完成这些步骤。

  1. On your lab Overview page, select the VM under My virtual machines.

    从“我的虚拟机”下的列表中选择 VM 的屏幕截图。

  2. On the VM's Overview page, select Auto-start under Operations in the left navigation.

  3. On the Auto-start page, select Yes for Allow this virtual machine to be scheduled for automatic start, and then select Save.

    在“自动启动”页上选择“是”的屏幕截图。

  4. On the VM Overview page, your VM shows Opted-in status for autostart.

    显示已选中自动启动状态的 VM 的屏幕截图。

    还可以在“实验室概述”页上查看 VM 的自动启动状态。

    显示实验室概述页的屏幕截图,其中 VM 自动启动设置为“是”。