exam questions

Exam AWS Certified SysOps Administrator - Associate All Questions

View all questions & answers for the AWS Certified SysOps Administrator - Associate exam

Exam AWS Certified SysOps Administrator - Associate topic 1 question 216 discussion

A company hosts a web application on an Amazon EC2 instance. The web server logs are published to Amazon CloudWatch Logs. The log events have the same structure and include the HTTP response codes that are associated with the user requests. The company needs to monitor the number of times that the web server returns an HTTP 404 response.

What is the MOST operationally efficient solution that meets these requirements?

  • A. Create a CloudWatch Logs metric filter that counts the number of times that the web server returns an HTTP 404 response.
  • B. Create a CloudWatch Logs subscription filter that counts the number of times that the web server returns an HTTP 404 response.
  • C. Create an AWS Lambda function that runs a CloudWatch Logs Insights query that counts the number of 404 codes in the log events during the past hour.
  • D. Create a script that runs a CloudWatch Logs Insights query that counts the number of 404 codes in the log events during the past hour.
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Christina666
Highly Voted 9 months, 1 week ago
Selected Answer: A
Option A (Create a CloudWatch Logs metric filter that counts the number of times that the web server returns an HTTP 404 response) is the most operationally efficient solution. With a CloudWatch Logs metric filter, you can extract and count occurrences of specific patterns within your log data and create a custom metric based on those occurrences. In this case, you can create a metric filter that looks for the HTTP 404 response code in the log events and increments a counter for each occurrence. This way, you get a dedicated CloudWatch metric that represents the count of 404 responses, making it easy to set up alarms, dashboards, and other monitoring configurations based on this metric.
upvoted 5 times
Christina666
9 months, 1 week ago
Option B (Create a CloudWatch Logs subscription filter that counts the number of times that the web server returns an HTTP 404 response) is not a suitable option because a subscription filter is used to stream log events to other AWS services like Lambda, Kinesis, or Elasticsearch, and it doesn't directly provide a count of the occurrences.
upvoted 3 times
...
...
dangji
Most Recent 1 year, 3 months ago
Selected Answer: A
A https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/MonitoringLogData.html
upvoted 2 times
...
yeacuz
1 year, 3 months ago
Selected Answer: A
The answer is A: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/Counting404Responses.html
upvoted 4 times
...
zolthar_z
1 year, 3 months ago
Selected Answer: A
Ans is A
upvoted 3 times
...
ashu27
1 year, 3 months ago
Metric Filter
upvoted 2 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago