How can I find out the storage usage of a Redshift cluster?

0

I'm trying to estimate how much it will cost to enable AWS Backup across several Redshift clusters. How can I find out the total storage usage of a Redshift Cluster using the AWS API?

Blaine
질문됨 일 년 전483회 조회
1개 답변
0

This metric is not directly available but can be calculated using Cloudwatch get-metric-statistics and Redshift describe-clusters

aws cloudwatch get-metric-statistics --region <your-cluster-region> --metric-name PercentageDiskSpaceUsed --namespace AWS/Redshift --statistics Maximum --dimensions="Name=ClusterIdentifier,Value=<your-cluster-identifier>" --start-time <yyyy-mm-ddThh:mi:ss> --end-time <yyyy-mm-ddThh:mi:ss> --period 3600

This will give you PercentageDiskSpaceUsed in Percentage example 2.098025

aws redshift describe-clusters --cluster-identifier <your-cluster-identifier> --region <your-cluster-region>

This will give you TotalStorageCapacityInMegaBytes example 4000000

From these two values you will calculate 2.098025 percent of 4000000 to get storage usage in MB between the start time and end time. This should be a good estimate of the backup size for that cluster.

profile pictureAWS
답변함 일 년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠