What should the solutions architect do to meet this requirement?
Send Amazon CloudWatch logs to Amazon Redshift. Use Amazon QuickSight to perform further analysis.
Enable detailed monitoring on all EC2 instances. Use Amazon CloudWatch metrics to perform further analysis.
Create an AWS Lambda function to fetch EC2 logs from Amazon CloudWatch Logs. Use Amazon CloudWatch metrics to perform further analysis.
Send EC2 logs to Amazon S3. Use Amazon Redshift to fetch logs from the S3 bucket to process raw data for further analysis with Amazon QuickSight.
Explanations:
While sending CloudWatch Logs to Redshift and using QuickSight for analysis is a valid approach for log analysis, it’s not the most efficient or appropriate for performance analysis with a 2-minute granularity. CloudWatch metrics are better suited for this purpose. Also, sending all logs to Redshift can be costly.
Enabling detailed monitoring on EC2 instances provides metrics with a 1-minute granularity, which meets the requirement of no more than 2 minutes. These metrics are readily available in CloudWatch and can be used for performance analysis, alerting, and dashboarding. This is the most straightforward and efficient solution.
Using a Lambda function to fetch logs from CloudWatch Logs adds unnecessary complexity. CloudWatch metrics already provide the necessary performance data with the required granularity.
Sending EC2 logs to S3 and then using Redshift for analysis is a valid approach for log analysis, but it’s not the most efficient for performance analysis. It also adds unnecessary complexity and cost compared to using CloudWatch metrics directly. The granularity of the logs also depends on the application’s logging frequency, which is not guaranteed to be every 2 minutes.