‫So now let's talk about the ways
‫you can track your cost in the cloud.
‫The first way is to use the Billing Dashboard,
‫which will show you all the cost actually for the month,
‫the forecast, and the month-to-date.
‫This is a very high level tool,
‫but it will be helpful to just get an overview
‫of what's happening.
‫And on the same page,
‫you will also get access to the AWS Free Tier Dashboard
‫which will show you the usage for each three tier
‫based on what you've been doing so far for the month.
‫So I can access my Billing Dashboard by clicking
‫on my account and clicking on my Billing Dashboard,
‫or you can go to find services and just type billing
‫to also access your Billing Dashboard.
‫So the Billing Dashboard, as I said, is pretty high level.
‫It will show the cost for the month.
‫So for this month I spent $14.60.
‫This is on my course.
‫Why? Because I paid for my domain name for $12.
‫I paid for config. I said, config was not free.
‫I paid for KMS because I created a KMS key.
‫And again, that was not free.
‫And then finally,
‫I have some taxes associated with my account.
‫So this is how much I spent to date,
‫and it gives me a high level overview
‫of what's going on for my account.
‫If I scroll down,
‫I can see the Top Free Tier usage by service.
‫So again, part of my dashboard.
‫And if I want more information, I can click on view all,
‫and this will give me my Free Tier service usage.
‫And I can see, for example, that for Amazon is free.
‫I have this many request and here's my forecasted usage.
‫And so I will see that I will be over the free tier.
‫So maybe I want to disable what is doing request,
‫which I expect it to be
‫the server access logging, for example.
‫And for Amazon,
‫it's free for the request
‫as well here on the get request, I'm good to go.
‫I'm still under the free tier,
‫and my forecast is also good as well.
‫For EC2, I can see that I've used 18 hours
‫of t2.micro so far.
‫My forecasted usage is 177 hours,
‫and I have overall in the month,
‫750 hours of t2.micro that is going to be free.
‫So this Free Tier service usage dashboard
‫is really helpful to see how your tracking
‫on your cost for this course.
‫And obviously if something looks wrong,
‫for example, for Amazon is free,
‫free to delete all the buckets
‫and you should be good to go, and it will be a lot safer.
‫Okay, so next we want to explore our bill a bit deeper.
‫So for this, we're going to use Cost Allocation Tags.
‫They will allow us to track our cost
‫on a detailed level and group them together.
‫For example, I have defined a Cost Allocation Tag,
‫and then you export your report,
‫and then you would get the cost
‫by category in Excel formats.
‫So for this, you can use different tags.
‫You can use the AWS generated tags, for example.
‫They will be automatically applied
‫to the resource that you create
‫and they will start with the AWS prefix.
‫For example, aws:createdBy,
‫and you can also define your own user tags
‫that will be defined the user
‫that will start with a prefix user:.
‫And this will be helpful, for example,
‫to tag your resources and then have them grouped
‫by cost center, by tag, by owner, by stack,
‫by application, and so on.
‫You can use tagging as well to create groups.
‫So tags are used for organizing resources.
‫For example, your EC2 instances,
‫your images, your load balances, your security groups,
‫your RDS databases, your VPC resources, Route 53,
‫your IAM users, et cetera, et cetera.
‫And if we create resources through CloudFormation,
‫they will all be tagged the same way.
‫If you're member it from the CloudFormation hands on.
‫There is free naming for your tag.
‫You can do whatever you want.
‫But common tag names are going to be Name, Environment,
‫Team, cost center, and so on.
‫And these tags can be used for cost reasons, obviously,
‫but also to create resource groups
‫to create, maintain, and view a collection of resources
‫that will share the common tags,
‫and you can edit those using the Tag Editor.
‫So to show you where that would be,
‫you would go in the search and you type resource groups,
‫and you arrive onto the resource groups
‫and Tag Editor console,
‫and you open one tab here and one tab for Tag Editor,
‫and this would allow you to edit your tags
‫for your resources.
‫So for example, for the Tag Editor in here
‫I can look at resource types of, for example,
‫security groups for EC2, and I will search my resources.
‫I will find all the security groups and I can, for example,
‫manage the tag of the selected resources,
‫and say that, yes, I'm going to add a tag of department
‫and then say, IT.
‫Review and apply the tag changes,
‫and it will apply the tag to all these resources.
‫And then I can create resource groups.
‫And I say, okay, it's going to be tag based.
‫I can select the resource type or so do all resource types.
‫So this is great.
‫And I will say, for example,
‫that I want my departments to be IT, add it,
‫and here I will have to see
‫that if I preview my resource groups,
‫I can find the five security groups
‫that I've tagged from before,
‫then we can call it IT resources
‫and then create on create group.
‫And we don't need a space.
‫I'm going to have IT-Resources.
‫Here we go.
‫And I have created my first resource group
‫based on this tag.
‫And this is very helpful to see what belongs
‫to different departments.
‫And you can use these tags for cost purposes.
‫So on the left hand side,
‫I can click on Cost Allocation Tags,
‫and then we can see all these tags right here,
‫activate them, and then generate a report
‫based on these tags.
‫So now let's talk about the reports we can generate in AWS.
‫We can generate a cost and usage report
‫to dive deeper into your cost and usage,
‫and they will give you an information
‫and it's going to be the most comprehensive sets
‫of cost and usage data available on AWS.
‫It will include all the additional metadata about services,
‫the pricing, and the reservations.
‫So you can get some information, for example,
‫around your Amazon EC2 Reserved Instances usage.
‫This cost report will give you all the AWS usage
‫for each service category used by an account
‫and its IAM users in hourly or daily line items,
‫as well as any tags that you have activated
‫for cost allocation purposes.
‫And this report can be integrated and analyzed
‫using Athena, Redshift or QuickSight
‫which is a dashboarding tool.
‫So this report looks like this.
‫It is going to be the most granular report you can get
‫with the most comprehensive data,
‫and will describe everything
‫for every cost when it was incurred, why it was incurred,
‫and the description of the associated cost.
‫So this is definitely a report you may want to use
‫to analyze your bill in details,
‫and really understand where a charge is coming from.
‫Next, we have Cost Explorer which is a more visual tool
‫in which we visualize, understand,
‫and manage your cost and usage over time.
‫You can create custom reports that will analyze
‫the cost and data, but it is for a high level, okay?
‫You can get your total cost and usage across all accounts,
‫or monthly, or hourly, or at the resource level.
‫And with this Cost Explorer tool,
‫you will be able to access your optimal savings plan
‫to lower the prices on your bill.
‫And most importantly,
‫you can forecast usage up to 12 months
‫based on the previous usage which is an exam question.
‫So if you're looking for a tool that will allow you
‫to forecast your bill for 12 months ahead,
‫then it's going to be Cost Explorer.
‫So here is an example,
‫with Cost Explorer you can get the Monthly Cost
‫by AWS Service.
‫And as you can see here,
‫you will get these graphs based on each different month.
‫And it will give you, in example, for EC2 Instances,
‫which one are costing you money, as well as the types.
‫You can get hourly and resource level information.
‫So this is your cost every hour with,
‫again, the cost defined by EC2 Instance,
‫so you can understand which EC2 instance
‫is costing you more every single hour.
‫And we can define Savings Plan,
‫which is again, an alternative to using Reserved Instances.
‫And so you would get recommendations
‫on savings plans right away, directly from Cost Explorer.
‫Finally, as I said, you can forecast usage on Cost Explorer.
‫So for example, you can have a look at your previous cost
‫and then you can go up to 12 months ahead of time
‫to forecast your usage and see how much is going to cost you
‫to use AWS in the future based on the growth
‫you have been experiencing in the past.
‫So you will find the Cost and Usage Reports
‫on the console on the left hand side,
‫to just enable the reports and then create the reports.
‫So you need to enable those if you wanted to have it,
‫and it will take about 24 hours to populate them,
‫and you can create a report.
‫I'll call it demo report, that will include everything,
‫including maybe resource IDs, click on next,
‫and then I could deliver it to an S3 bucket.
‫So I would select a bucket I have,
‫for example, my demo ccp-cloudfront, who knows,
‫and then I'll click on next.
‫I will say, yes, I will allow the building report
‫to write my S3 buckets, click on save,
‫and then I will say, okay, this is a Valid Bucket,
‫and it works.
‫I want to get hourly data.
‫I want to create a new report version,
‫and maybe you want to enable report data integration.
‫I'll click on next, and then click on Review and Complete,
‫and this will deliver to me, my billing reports,
‫my cost and usage reports directly
‫into this Amazon S3 bucket.
‫So this is one example.
‫And then the second one is going to be around Cost Explorer,
‫which is a more visual way to view your bill.
‫So this is going to give me some usage data in my accounts.
‫Obviously, I don't have many cost in here
‫so it's not going to be fascinating,
‫but what you can do,
‫again, with Cost Explorer,
‫is to get recommendations on saving plans
‫on the left hand side,
‫so if you want to save some more,
‫so these are the recommendations.
‫And then you can also forecast the month end cost directly
‫based on previous month usage,
‫all the up to 12 months ahead.
‫So that's it for this lecture, I hope you liked it
‫And I will see you in the next lecture.