AWS Certified Cloud Practitioner (CLF-C02)Cloud Technology and ServicesHard
A systems administrator wants to centrally collect, store, and search application log files generated by dozens of EC2 instances running a fleet of web servers, without managing a separate logging server. Which AWS capability should the administrator use?
- ACloudWatch Logs
- BAWS CloudTrail
- CVPC Flow Logs
- DCloudWatch Metrics
Show answer & explanationAnswer & explanation
Correct answer: A. CloudWatch Logs
CloudWatch Logs allows you to install an agent on EC2 instances to collect, centralize, monitor, and search application and system log files without needing to manage a dedicated logging server.
Why the other options are wrong
- B. CloudTrail records AWS API calls and account activity, not custom application logs from EC2 instances.
- C. VPC Flow Logs capture network traffic metadata at the VPC level, not application log files.
- D. CloudWatch Metrics tracks numerical performance data like CPU utilization, not raw log file content.
CloudWatch Logs
A CloudWatch feature that centralizes, stores, and enables searching of log files from EC2 instances, Lambda, and other AWS resources.
- Requires the CloudWatch agent on EC2 for OS/application logs
- Supports log groups, streams, and metric filters
- Can trigger alarms based on log patterns
Memory trick: CloudWatch Logs is the central filing cabinet for your app's diary.