Azure cost optimization by Azure AI

Anshal 1,966 Reputation points
2024-03-25T10:28:55.4166667+00:00

Hi friends, Azure charges per hour ,but if I use the service for only 30 mins will I am charge for 1 hour? How does this costing mechanism works? And my requirement is to identity idle resources such as VMs and Databricks clusters , I need to use Azure ML to identify them and dynamically shut down? Is it possible ?

Azure Machine Learning
Azure Machine Learning
An Azure machine learning service for building and deploying models.
2,605 questions
Azure Databricks
Azure Databricks
An Apache Spark-based analytics platform optimized for Azure.
1,960 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
9,711 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Amira Bedhiafi 16,071 Reputation points
    2024-03-25T12:49:31.66+00:00

    For many Azure services, billing is indeed done on an hourly basis, but it's essential to differentiate between services charged by actual compute time and those with a minimum time unit charge. For instance:

    • Virtual Machines (VMs): Azure VMs are billed by the minute, meaning you're only charged for the number of minutes your VM is running. If you use a VM for 30 minutes, you'll only be charged for 30 minutes of usage.
    • Azure Databricks: Billing for Databricks units (DBUs) can be more complex, as it depends on the type of Databricks cluster you're running (interactive or automated), and charges are generally per minute of cluster usage.
    • Azure Data Factory: Typically charges for the orchestration of activities and not for the time the service is active/idle. The cost is associated with pipeline runs, activity runs, and triggered runs.

    Use Azure Monitor to track the usage and performance metrics of your resources. This includes CPU, memory usage, network activity, etc., which can help identify when a resource is underutilized or idle.

    https://learn.microsoft.com/en-us/answers/questions/380422/pricing-vm-hourly-or-minute

    https://azure.microsoft.com/en-us/pricing/details/virtual-machine-scale-sets/linux/

    https://learn.microsoft.com/en-us/answers/questions/401124/if-i-use-a-vm-only-for-30-minutes-in-whole-lifetim


  2. Pinaki Ghatak 2,400 Reputation points Microsoft Employee
    2024-04-29T19:41:06.1833333+00:00

    Hello @Anshal

    Yes, Azure charges per hour, but if you use a service for only 30 minutes, you will be charged only for the minutes used, not for the full hour.

    Azure rounds up usage to the nearest minute, so if you use a service for 31 minutes, you will be charged for 31 minutes of usage. Regarding your second question, it is possible to use Azure Machine Learning to identify idle resources such as VMs and Databricks clusters and dynamically shut them down.

    You can use Azure Machine Learning to create a model that analyzes usage patterns and determines when a resource is idle. Once the model identifies an idle resource, you can use Azure Automation to shut it down.

    You can also use Azure Cost Management and Billing to monitor your usage and costs and set up alerts to notify you when usage or costs exceed a certain threshold.

    This can help you identify idle resources and take action to reduce costs. I hope this helps.

    0 comments No comments