How to Enable Auto Start Stop for Azure VM

1707503499997
Written by: Craig Wester
Published: February 9, 2021

Contents

ShowHide

    You can enable this feature to save money on Azure servers that you are paying for monthly. This allows you to shut off the VM’s on non-use hours such as overnight or weekends and have them automatically start back up when you need them. It is a simple way to save money, as you save on the VM costs and any licensing costs associated such as SQL or Windows.

    Watch the Video to See How to Enable Azure VM Auto Start/Stop

     

    Use the feature with classic VMs

    If you are using the Start/Stop VMs during off-hours feature for classic VMs, Automation processes all your VMs sequentially per cloud service. VMs are still processed in parallel across different cloud services.

    For use of the feature with classic VMs, you need a Classic Run As account, which is not created by default. For instructions on creating a Classic Run As account, see Create a Classic Run As account.

    If you have more than 20 VMs per cloud service, here are some recommendations:

    • Create multiple schedules with the parent runbook ScheduledStartStop_Parent and specifying 20 VMs per schedule.
    • In the schedule properties, use the VMList parameter to specify VM names as a comma-separated list (no whitespaces).

    Otherwise, if the Automation job for this feature runs more than three hours, it’s temporarily unloaded or stopped per the fair share limit.

    Azure CSP subscriptions support only the Azure Resource Manager model. Non-Azure Resource Manager services are not available in the program. When the Start/Stop VMs during off-hours feature runs, you might receive errors since it has cmdlets to manage classic resources.

    View the feature

    Use one of the following mechanisms to access the enabled feature:

    • From your Automation account, select Start/Stop VM under Related Resources. On the Start/Stop VM page, select Manage the solution under Manage Start/Stop VM Solutions.
    • Navigate to the Log Analytics workspace linked to your Automation account. After after selecting the workspace, choose Solutions from the left pane. On the Solutions page, select Start-Stop-VM[workspace] from the list.

    Selecting the feature displays the Start-Stop-VM[workspace] page. Here you can review important details, such as the information in the StartStopVM tile. As in your Log Analytics workspace, this tile displays a count and a graphical representation of the runbook jobs for the feature that have started and have finished successfully.

    Related Posts