Soru

Zorluk: KolayHigh-Performing and Elastic Compute Solutions

A company has deployed a high-performance catalog search API on Amazon EC2 instances. The API application runs on the instances and is configured to listen for requests on port 8088. The instances are registered as targets in an Application Load Balancer (ALB) target group. The ALB health check status for all EC2 instances is reported as unhealthy, resulting in HTTP 502 (Bad Gateway) errors for clients. A configuration audit reveals that the target group's health check is configured to query port 80. Which action will resolve this issue and restore service availability?

  1. A
    Change the ALB listener port from 443 to 8088 to match the application port, allowing the health checks to bypass the target group configuration.
  2. Modify the target group configuration to use port 8088 or 'traffic-port' for the health check.Cevap
  3. C
    Launch the EC2 instances in a cluster placement group to automatically bridge the communication gap between port 80 and port 8088.
  4. D
    Configure the target group to use a spread placement group to ensure that the health checks are distributed across different physical hardware hosts.

Cevap

Modify the target group configuration to use port 8088 or 'traffic-port' for the health check.
The correct action is to modify the target group configuration to use port 8088 or 'traffic-port' for the health check. Since the API is configured to listen on port 8088, target group health checks sent to port 80 will fail because nothing is listening on that port on the EC2 instances. Aligning the health check port to port 8088 allows the load balancer to receive successful responses and mark the instances as healthy.

Adım Adım Çözüm

1
Identify the ports involved in the architecture.
The application listens on port 8088, but the ALB target group health checks are targeting port 80.
Understanding where the traffic is sent versus where the health checks are pointing helps locate the source of the HTTP 502 errors.
2
Determine the configuration setting causing the mismatch.
The health check port in the target group is set to a static value of 80, which does not match the application port.
By default, target group health checks target the registered traffic port, but an explicit override to port 80 will fail if the application is not listening on that port.
3
Align the health check port with the active application port.
Update the health check settings in the target group to use port 8088 or select the 'traffic-port' option.
This configuration allows the ALB to successfully probe the catalog search API, marking the targets as healthy and routing client traffic correctly.

Anahtar Kavram

ELB Target Group Health Check Configuration
Bu soruyu puanla