AZ-900 Microsoft Azure Fundamentals – NEW AZ-900 Course for 2021 – Managing Azure Costs
January 30, 2023

1. Overview of Azure Pricing

Section of this exam, it says describe Azure cost management and service level agreements and is worth ten to 15% of the overall score. So we can see that there are only two subsections in that. One has to do with planning and managing costs and the other has to do with service level agreements. This section of the course is going to talk about the cost element. And then in the following section we’ll talk about the service level agreements and service lifecycles and then and will be done. So thanks for sticking with me guys. I’m glad that you’re here. Let’s get right into talking about costs. So in some ways pricing within Azure is fairly complicated. Of course you can take advantage of that complication by saving a lot of money. Instead of having one fixed price from your current service provider that is relatively high, you could actually save money. But then pricing becomes more complicated.

That is the trade off, I guess. Every service that you use could or could not have different factors for billing. Some things are going to be free, some things are going to have a single monthly cost, and then other things are going to measure all the different elements. So let’s talk about those. First off, there are free services. We talk about the cloud, and it just seems like everything costs money. But you can create as many resource groups as you want. There are limits in terms of the subscription, in terms of the region, but resource groups don’t cost money. The virtual network by itself doesn’t cost money. Creating a basic load balancer doesn’t cost money.

The active directory tenants don’t cost money. I’ve got six or seven of them, et cetera. So we can see there’s a set of free services that don’t cost. Most other services are going to have some type of cost within the cloud environment. We call these things metered. So you’re either going to be tracking time, you’re going to be tracking gigabytes, you’re going to be tracking CPU utilization, number of executions. There’s different things you can meter. But just like an electricity meter at home, Microsoft is counting things that are crossing a wire. So for instance, in the pay for usage model, that is the consumption model. So if you are running functions and you’re going to get a million for free, and then it’s cost per million after that, then you’re going to have basically a pay for usage for that.

If we look at the Azure functions example, there is a free level. It’s twenty cents per million after that, which is pretty cheap. You compare that to a virtual machine. You can even get a virtual machine to play with for $20 a month. But you can play around with functions and you’d be hard pressed to incur any cost if you’re just playing with functions. And you’d have to have your functions running every second or multiple times a second just to exceed the number of free executions. If we look at those types of services, some of these are called serverless functions, and logic apps are paid per usage. Storage is pay per gigabyte. For an unmanaged storage account, the bandwidth leaving Azure has a cost to it. You get 5GB per free, and after that you’re paying per gigabytes and leaving Azure. These API within the machine learning cognitive services have a cost. Now the second type of model that we have for charging is pay for time. And so we’ve seen this in the virtual machines and the web apps. For virtual machines, there’s pay per second, so the billing stops the second the VM itself is stopped. Now I put an asterisk there because you’re also paying for storage. Just like anything, there’s two or three factors that are going to go into your bill with a virtual machine. The cost of the instances, only one of them, storage is the other, and the bandwidth used could be a potential third. Now, there are the ability to lock in some of your costs and get some stability to it, if that’s what’s important to you, if you’re like. No, we would rather have we’re going to pay a million dollars a month, but we would rather have that million known. We can budget for it, we get approval.

We don’t need to have it go down to 901 month and up to 1. 1 million the following month. So there are the abilities for reserved instances or running on an isolated environment, things like that, you’re going to pay for whether you use it or not. But that is stability and pricing. Now I mentioned just a few minutes ago about bandwidth being a cost. We always forget about that. But the 5GB leaving Azure is free and then you pay per gigabyte above it anytime. Data coming into Azure from the outside world is always free. We also have some of these types of restrictions on VNet to VNet communications. Depending on whether you’re using a peering relationship or you’re using a network gateway, you’re paying for data between regions, between virtual networks as well.

 So data charges is always interesting. We can see that it’s five cents to nine cents per gigabyte for most of North America and the EU. Germany has a higher cost. And so five point seven to ten cents per gigabyte. And as we go into Asia, Africa, Brazil, then the pricing goes up from there, up to maximum of for bandwidth in the Brazilian region. If you’re going to start using availability zones within that region, you’re going to have additional costs. We talk about there being the unlimited amount of data, and you could certainly re envision that. But let’s say you had a petabyte of data sitting inside of Azure and you wanted to download that into your own environment. Well, that is five cents per gigabyte. That’s going to run you $50,000. So data transfers, nothing to sort of scoff at, but you really need to get to. We’re talking about petabytes here. Huge amount of data being transferred in order to reach that level. Hopefully your business supports that.

2. Saving Money on Azure Resources

Let’s talk about saving money within Azure. How would we go about looking at our usage of Azure resources and how do we reduce the cost? Well, Azure Advisor is a good place to start. If you remember, Azure Advisor does make recommendations based on your actual usage of Azure. And one of those things that it does recommend are ways of doing cost savings. And so if you have virtual machines which are underutilized, it will show up in Advisor. If you have reservations that are not being used, it’ll show up in Advisor. So first thing I would do is I would log into my account, I would go into Azure Advisor, look on the Cost tab under Settings, and find those recommendations. It may or may not be possible for you to implement all of the recommendations, but you certainly look at it. The next thing I would look at is whether some resources can be shut down when they’re not being used.

There is an auto shutdown option within virtual machines. And so if you’ve got development resources and you know that after 10:00 P. m. And rarely are developers still working, you can have an auto shutdown at 10:00 P. m. And you can even have it auto turn on at 08:00 A. m. . And those 10 hours are basically going to cut your development and QA costs almost in half, right? Just those taking the 10 hours out of the day where those resources are not likely to be used. You could even be a bit more aggressive with that and allow developers to turn them back on if they do need them. That’s sort of one option is the auto shutdown. Looking into the storage options. So there is a thing called lifecycle management within storage, and you can basically get files that are not used into a cheaper level of storage.

 And then if you’ve got files that are never used, you can move them into an archived tier. Storage can actually be reduced by 90%. The costs of the Hot Tier are ten times higher than the cost of the archived tier. If you’ve got massive amounts of backup files that are rarely ever needed, and even if you do need them, you can wait a few hours to get them look into the lifecycle options within a storage account. Even moving from the Hot Tier to the Cool Tier cuts your costs in half. Those files can be accessed instantly. So play around with that and see if you can cut your storage costs by 20 or 30% if you just utilize the Cool tier more often. We talked a couple of times about Azure reserved instances.

 If you know you’re going to be using a virtual machine for the next year, guaranteed the project is going to be running, there’s no plans to shut it down. You can just convert those to reserved instances and lock in some savings 20%, 30%, 40% or more. If you know that you can go up to three years, you can lock even more savings. And we haven’t even talked about hybrid instances where you’re basically using the licenses from your enterprise agreement into Azure, you can set billing alerts. And so billing alerts, we should know, doesn’t actually stop resources from exceeding a particular price target. But if something is a runaway, let’s say there’s a service that was started and was supposed to be stopped, but it wasn’t. The billing alert can actually send you an SMS or email you and just say, hey, we’ve now reached 75% of our monthly bill. And you’re like, wait, it’s only the 10th. Why are we already at three quarters? And get in there and fix it? So billing alert really is sort of that last line of defense so that you have no surprises. We saw in the policy section of this course that you can go in and restrict certain resources from being used. And so you can just say, this whole area of virtual machines, we have a policy that we don’t use them, or other restrictions like that. So using policy to ensure that people are not running resources that are more expensive than you allow. Now of course, you can always give an exception to that policy for people who get approval for that.

 Once you move your application to the cloud, one of those next things you want to look into is the concept of auto scaling. So being able to use less resources than you currently use, but then scale up when the demand reaches the requirement, then that’s a great way to save money. On the flip side of that is being able to downsize resources. Now this could be a permanent downsize. So when you do some research and you find that applications are never exceeding 10% CPU utilization in a particular machine, you can start to look at smaller machines who can run that same workload with the same level of performance and cut your costs in half from just moving to smaller virtual machines. Again, you can move into app services, move into functions. There’s obviously opportunities in there. Another aspect of saving money is making sure that all of the resources are accounted for. One of the worst things that can happen, I guess, is if you’ve got a big account with hundreds of resources and you just have no idea, is this important? Can I shut this down? Who started this? Forcing tags is one way to make sure that there’s always going to be someone who you can go to and say, hey, this VM has been running for six months. Do you still need it? What’s it for? What’s the billing code? Making sure that resources are tagged is one way of being able to account for costs. We haven’t talked much about this, but there is a feature. It’s relatively new within Azure called spot pricing.

So if you have really low priority workloads that can run anytime, you have this job it needs to run. It doesn’t have to run right now. It can run anytime in the next week or so. You can actually go and bid on low priced virtual machine time. And if you can figure that out automate that, then you can basically run a job when the prices are cheapest instead of paying the rack rate. It’s almost like monitoring a hotel website site for when rooms go on sale or monitoring flights for the cheapest flight. You can do that for your virtual machines. Now the downside of that, of course, is you don’t get that on demand and at any time someone can come along and willing to pay full price. So it’s like a standby ticket on an airplane. But if it’s a low priority workload, then you can save some money.

3. Azure Pricing Calculator

Now one of the tools that will become quite helpful when you’re looking into the pricing of Azure services is the Azure pricing calculator. It’s on the Azure website. If you go to Azure Microsoft. com, you’ll see a link along the top menu button, or you can say Pricing Calculator to get there. And you can see almost all of the available Azure services, add them to your car, effectively set the settings, choose your options, and Microsoft will attempt to estimate your future bill. Now it is hard or difficult to make accurate estimates. It does require maybe you have some existing data from your existing data center, or you have some fairly educated guesses, but you’re going to make a first attempt at this and it’s hard to say it’s going to be 100% accurate.

That’s just the reality of it. For instance, when you’re looking at all of the different options, you’ll be presented with different regions, for instance, and then you’ll see the pricing of services is different. If you’re in East US. Versus northern Europe, the tiers of various services. So you could be in standard tier or basic tier or premium tier. You get different performance expectations. Business critical applications are an option as well, the type of your subscription. So if you’re using a pay as you go subscription versus you have an enterprise agreement, various plans have different pricing, you can choose to purchase support and so you get dev level support or premium level support. There’s going to be a cost to that mentioned previously in this course. If you choose the production level licenses for things, there are different licenses for dev and tests. And so when you’re in the pricing calculator, make sure you choose that correctly.

But even when you’re in production, when you’re in the Azure environment, making sure you have the right license is going to be affecting your cost. So once you’ve set up your potential future environment, you’ve estimated the cost, first of all, you can save this and come back to it. It might take you several days to build up a really accurate estimate, and then you can export that and share the estimate around. So it becomes a link that you can send to people and they can come and see what your assumptions were, how you arrived at those numbers. They can give you feedback on that. Now related to the pricing calculator is what’s called the Total Cost of Ownership, or TCO calculator. Microsoft has had this view, and almost always had this view, that the cost of running an application is more than just the cost of the server itself. So you might see that the posted price for an Azure virtual machine is twenty five cents per hour. But comparing that to the cost of running it in your own environment, it’s not exactly into Apple’s comparison because if you are running that machine in your own environment, you would have to pay not only for the hardware.

 But you would have to pay for electricity. You would have to pay for cooling for that machine, internet connectivity, the land space, if you will. Like, just you know, if you’re going to have 100 machines, you need a place geographically to store them. There’s labor when it comes to setting them up, ongoing maintenance, repairs, things like that, and backing up those machines so that they can be restored in an emergency. All that stuff that Microsoft gives you when you’re paying $0. 25 an hour for a virtual machine, that is the total cost. So if you go to the TCO Calculator, also available in the Azure menu, and at this URL, then you’ll be able to build an estimate of the cost of running a solution in Azure versus the real cost of running a solution in your own environment.

 You’ll be able to compare again the labor costs and the electricity costs and see how much savings you can. This is the kind of thing that will help you make the business case. If you need to go to your executive team into management and say, hey, we should do this, and we can save $100,000 over five years, then they might be able to grant you the authorization, the budget to do the project. And so the TCO Calculator is perhaps your friend in that.

4. Azure Cost Management

Pricing calculator is great for predicting future costs and for sort of projecting out a year or two years in the future. But if you need to look at historical costs, if you’re actually already in Azure and you want to see what your spending is like, there’s a tool called Azure Cost Management. Now it’s a free tool, hopefully. And Azure, in Azure you can see you’re not only your invoices, so the historic historical invoices of you being charged by Microsoft, but the actual current resources that are charging to your account day by day. There’s many ways to sort of cut and view the different numbers. So if we look at a screenshot from the Cost Management and Billing section, we can see that there’s almost a dashboard view here. You can see the spending over time and you can maybe detect if there’s any strange patterns in there. And it also allows you to have different time periods, filters, views. You can be as granular or as broad as you wish. This again allows you to track spending over time. And if you are using the budgeting feature, then you can obviously compare the actual spending with the amount that you actually budgeted and maybe you’re under or over on that. And so the Cost Management section contains that if you want reports to be regularly generated and you to be notified of these reports, you can set up a report schedule and notification within that as well. So there is a whole section of the Azure environment that dealing with costs and how you’re going to find what you’re spending on, what you can do to adjust that. Maybe it makes perfect sense to you or maybe there’s something to look into.

Leave a Reply

How It Works

img
Step 1. Choose Exam
on ExamLabs
Download IT Exams Questions & Answers
img
Step 2. Open Exam with
Avanset Exam Simulator
Press here to download VCE Exam Simulator that simulates real exam environment
img
Step 3. Study
& Pass
IT Exams Anywhere, Anytime!