In the event that the condition of the target is a value different from healthy If the target's status is not healthy, the API gives an explanation code as well as a description of the issue and the console displays that same information in the form of a tooltip. Reason codes that start at Elb originate from the load balancer side , and reason codes that start by the word "target" originate from the side that targets. You can even check out the details of AWS with the AWS Cloud Migration. You get 302 when performing URL redirection, any ELB Health check will look for success code 200 for the health check to pass. In ALB, this can be configured under health check in the ELB console.
To modify the health check settings of a target group using the console
- Open the Amazon EC2 console at https://console.aws.amazon.com/ec2/.
- On the navigation pane, under LOAD BALANCING, choose Target Groups. Select the target group.
- On the Health checks tab, choose Edit.
- On the Edit target group page, modify the setting Success Codes to 302 or as needed, and then choose Save.