Question

Difficulty: HardAWS Compute Optimizer and Right-Sizing

A company runs a batch processing application on a fleet of Amazon EC2 instances within an AWS Organizations structure. A SysOps Administrator wants to use AWS Compute Optimizer to obtain right-sizing recommendations for these instances. Currently, Compute Optimizer only provides recommendations based on CPU and network metrics, and reports that memory metrics are unavailable. Which two actions must the administrator take to enable AWS Compute Optimizer to deliver memory-aware right-sizing recommendations? (Select two.)

  1. Install and configure the Unified CloudWatch Agent on the EC2 instances to publish memory utilization metrics to Amazon CloudWatch.Answer
  2. Associate an IAM instance profile with the EC2 instances that includes the CloudWatchAgentServerPolicy managed policy.Answer
  3. C
    Enable Amazon EC2 detailed monitoring for the instances within the AWS Organizations management account.
  4. D
    Activate the cost allocation tags for memory utilization in the AWS Billing and Cost Management console.
  5. E
    Configure AWS Cost Anomaly Detection to track memory utilization anomalies and forward them to AWS Compute Optimizer.

Answer

To enable memory-aware recommendations in AWS Compute Optimizer, the SysOps Administrator must install and configure the Unified CloudWatch Agent on the EC2 instances to publish memory metrics, and associate an IAM instance profile with the instances that includes the CloudWatchAgentServerPolicy managed policy to grant the necessary permissions.
AWS Compute Optimizer relies on OS-level memory metrics to perform memory-based right-sizing analysis. These metrics must be sent to Amazon CloudWatch using the Unified CloudWatch Agent, and the EC2 instances must have an IAM role/instance profile with permissions (such as CloudWatchAgentServerPolicy) to write those metrics to CloudWatch.

Step-by-Step Solution

1
Deploy and configure the Unified CloudWatch Agent on the EC2 instances.
The agent collects OS-level memory utilization metrics and publishes them to Amazon CloudWatch under the CWAgent namespace.
AWS Compute Optimizer does not receive memory utilization metrics by default because they are OS-level metrics not visible to the hypervisor.
2
Ensure the EC2 instances have the required IAM permissions by attaching an instance profile with the CloudWatchAgentServerPolicy.
The CloudWatch Agent on the EC2 instances is authorized to write custom metrics to the CloudWatch service.
Without these permissions, the agent cannot publish the memory metrics, meaning AWS Compute Optimizer will not have the data needed to perform memory-aware analysis.

Key Concept

AWS Compute Optimizer requires the Unified CloudWatch Agent to analyze EC2 instance memory utilization because memory is an OS-level metric that is not available via default CloudWatch hypervisor metrics.
Rate this question