AWS Certified DevOps Engineer - Professional free question 9 / 10 · Domain 5: Incident and Event Response
The targets of an Application Load Balancer stay unhealthy with the reason code Target.ResponseCodeMismatch. The health check path of the application returns HTTP 204 when the application is healthy. What should the team change?
- Raise the healthy threshold count so that more successful responses are required
- Raise the health check timeout so that the application has more seconds to answer
- Change the success codes of the health check so that they include 204, for example 200,204
- Switch the health check protocol from HTTP to HTTPS so that the load balancer reads the code
Show the answer and explanation
Answer: C
Why this is correct
The reason code Target.ResponseCodeMismatch says the health check failed with a response code that the load balancer does not treat as success. The matcher, shown as Success codes in the console, defaults to 200, and for HTTP it accepts values from 200 to 499 as a list or a range. Adding 204 to the matcher makes the healthy answer of the application count as a passed check.
Why the other options are wrong
"Raise the health check timeout so that the application has more seconds to answer" … The timeout is the time during which no response means a failed check. The reason code Target.ResponseCodeMismatch means a response arrived with a code that the matcher does not accept.
"Switch the health check protocol from HTTP to HTTPS so that the load balancer reads the code" … The protocol decides how the load balancer sends the request. The load balancer already receives the 204 code, which is the value the success code setting rejects.
"Raise the healthy threshold count so that more successful responses are required" … The healthy threshold count is the number of consecutive successful checks needed. A 204 response never counts as successful with the default success code of 200.
Key points
ResponseCodeMismatch: fix the matcher (success codes). Timeout problems show as Target.Timeout.