You just join a company as a DevOps engineer and you need to manage an AWS account.
A big number of AWS resources are deployed in the account such as Auto Scaling groups, S3 buckets, etc.
In order to better understand the cost spent in the account, every department starts to attach a user-defined tag CostCenter:xxxx to its AWS resources.
You also configured the AWS Cost and Usage Reports and used an S3 bucket to save the reports.
After several days, you check the reports in the S3 bucket and find that the reports do not use the CostCenter tag to organize the resources or track the AWS costs.
Which of the following steps do you miss?
Click on the arrows to vote for the correct answer
A. B. C. D.Correct Answer - A.
In order to enable the user-defined cost allocation tags, you need to activate the tags first.
Details can be found in https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/cost-alloc-tags.html.
Option A is CORRECT: Because you need to activate the tags in the Billing and Cost Management console for the cost allocation tracking.
Option B is incorrect: The reports have already been put in the S3 bucket successfully, which means there is no problem for the S3 bucket policy permissions.
Option C is incorrect: Because both AWS-Generated Cost Allocation tags and user-defined tags are supported by the AWS Cost and Usage Reports.
Option D is incorrect: Because there is no such requirement to append the “aws:” prefix to the user-defined cost allocation tags.
The problem stated in the question is that the AWS Cost and Usage Reports are not using the user-defined tag "CostCenter:xxxx" to organize the resources or track the AWS costs. To fix this, one needs to identify the step(s) that were missed.
Option A suggests activating the CostCenter tag in the Billing and Cost Management console, which will allow the usage and costs to be grouped by the tag. This option is a valid step to take as it enables AWS to use the user-defined tags to organize the resources and track the costs.
Option B suggests modifying the S3 bucket policy to allow the AWS Cost Allocation Tags service to write objects in the S3 bucket. This option is also a valid step to take as it ensures that the AWS Cost Allocation Tags service has the necessary permissions to write the reports in the S3 bucket.
Option C states that AWS Cost and Usage Reports only support AWS-Generated Cost Allocation Tags, and user-defined tags are not supported. This option is incorrect, as AWS Cost and Usage Reports do support user-defined tags. In fact, the question states that the departments are attaching the user-defined tag "CostCenter:xxxx" to their AWS resources.
Option D states that user-defined tags have specific formats in AWS Cost and Usage Reports, and the tag keys must have a prefix of "aws:" otherwise the tags are not applied in the reports. This option is partially correct. AWS recommends using a standardized format for user-defined tags in AWS Cost and Usage Reports. The standardized format is to use a prefix of "aws:" for the tag keys, followed by a forward slash and the tag name, like "aws:CostCenter". However, this is not mandatory, and one can use other tag keys as well. In this case, since the tag key is "CostCenter", it should still be applied in the reports, even if it doesn't have the "aws:" prefix.
Therefore, the correct steps to take to fix the issue would be to activate the CostCenter tag in the Billing and Cost Management console and modify the S3 bucket policy to allow the AWS Cost Allocation Tags service to write objects in the S3 bucket. Option C is incorrect, and option D is only partially correct.