I have a working EC2 instance I'd like to place, along with a copy, behind an Elastic Load Balancer, but I can't get it to work.
ELB Settings:
- Ports: ELB HTTP:80 -> EC2 HTTP:80, default VPC
- Security groups: AWS-OpsWorks-LB-Server
- Health Check: HTTP, 80, /
- EC2 Instance: My working EC2 instance
Hitting the ELB directly returns a 503 error code.
Digging into the Apache logs of my EC2 instance, I see:
x.x.x.xx - - [18/Feb/2016:14:21:18 +0000] "GET / HTTP/1.1" 400 52 "-" "ELB-HealthChecker/1.0"
The ELB health check is returning 400, Bad Request, but pretty sure the "/" path is correct as I have a working Drupal instance in /var/www/html.
I don't think the problem is the security groups either, since if I use the exact same ELB, as is, and fire up a new EC2 instance as a PHP App Server via AWS OpsWorks, the ELB works fine.
I'm assuming I must be missing some package or configuration but looking over the Chef 11 recipes AWS uses to build a PHP App Server it's hard to see what I've forgotten.
Thoughts?