This is an original sample question written by itmoshi based on the exam objectives.
An operations team wants to be notified when memory utilization on a fleet of Amazon Linux EC2 instances exceeds 90%. The EC2 metrics in CloudWatch show CPU utilization and network traffic, but there is no memory utilization metric. How should the team meet this requirement?
Show answer and explanation
Answer:A Memory utilization is not among the default EC2 metrics, so collect it with the CloudWatch agent and alarm on it.
Why it is correct
The metrics EC2 publishes to CloudWatch by default, such as CPU utilization, network, disk I/O and status checks, are values available from outside the instance; guest OS memory utilization is not among them. The CloudWatch agent publishes in-guest values such as memory utilization (mem_used_percent) and disk utilization as custom metrics. An alarm on that metric that notifies through SNS when it exceeds 90% meets the requirement.
The other options
- ✗ B Enabling detailed monitoring does not provide guest OS memory utilization. Detailed monitoring collects EC2-published metrics at a finer interval; use it when you need to spot changes in existing metrics sooner.
- ✗ C VPC Flow Logs record network traffic information and tell you nothing about memory. Use them to investigate accepted or rejected traffic and to analyze traffic patterns.
- ✗ D CloudTrail records API call history, not resource usage inside an instance. Use it to audit who did what and when.
Key takeaway
EC2-published metrics → values available from outside the instance (CPU, network, disk I/O, status checks and so on). In-guest values such as memory or disk utilization → CloudWatch agent. Detailed monitoring → EC2 metrics at a finer interval, nothing more. API activity → CloudTrail.