¿How does the billing of Cloudwatch Custom Metrics work?

0

I have installed in two of my ec2 instances the cloudwatch agent to retrieve the data of the memory and disk usage. I was expecting that to count as 2 custom metrics for each of the instances (4 in total), but when I check the list of the free tier offers in use in Billing and Cost Management, I don't see it counting them, since it says I have 0 metrics in usage. Billing and Cost Management

This is the configuration of the cloudwatch agent:

{
	"metrics": {
		"append_dimensions": {
			"InstanceId": "${aws:InstanceId}"
		},
		"metrics_collected": {
			"mem": {
				"measurement": [
					"mem_used_percent"
				],
				"metrics_collection_interval": 60
			},
            "disk": {
				"measurement": [
                     "disk_used_percent"
				],
				"metrics_collection_interval": 60
			}
		}
	}
}

I used these metrics in a dashboard and one alarm. I'm a bit lost with how the billing of the metrics works. I intend to track these metrics in at least 4 instances, so I would like to understand this first.

1回答
2
承認された回答

Hi, you are right to assume that memory and disk count as 2 custom metrics for every instance, as the metrics are defined by their namespace, name and set of dimensions.

Please note that Billing and Cost Management is not updated in real time, so you will see accrued usage after 6 to 24 hours.

Also note that metrics usage is pro-rated by the hour, so 1 custom metric is incurred only after sending data for 744 hours to a metric (720 hours if the month has 30 days). If you look at your usage after one business day where your 8 EC2 instances ran for 8 hours, you have sent about 8 metrics for 8 hours, that would be 8 x 8 = 64 hours of sending data to metrics, so the billing and cost management would be aware of only 64 / 744 = 0.09 metrics after that duration.

profile pictureAWS
回答済み 5ヶ月前
profile picture
エキスパート
レビュー済み 5ヶ月前
  • Thank you very much! Your answer was very helpful.

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ