5

I have an ELB. It has the address myelbname.eu-west-1.elb.amazonaws.com as one would expect.

I also have an EC2 instance behind that ELB. The load balancer is saying that the instance is healthy (the status is "In Service").

I can access the EC2 instance over IP on my network (using VPN to the VPC) but if I go to the A record of the load balancer in a browser then it can't be found.

Also, if I run nslookup it does show an IP address for the load balancer.

I've also tried adding a CNAME record and pointing it to the ELB's DNS name but that didn't work.

  • 1
    Make sure your ELB is placed in AZs with an internet gateway, so they can access the public internet. – ceejayoz Dec 31 '13 at 15:03
  • The VPC has an internet gateway (as far as I can see you can't assign an intenet gateway to an AZ, just the VPC) – Piers Karsenbarg Dec 31 '13 at 15:06
  • Sorry, should've said subnet. – ceejayoz Dec 31 '13 at 15:08
  • Can you make that an answer please. – Piers Karsenbarg Dec 31 '13 at 16:00
  • Certainly, I have done so. – ceejayoz Dec 31 '13 at 16:01
4

ELBs must be in a subnet with an internet gateway. Placing an ELB in a private subnet makes it only available within the VPC's network.

  • 2
    Or, more precisely, in a subnet with a default route pointing to the Internet gateway (not a NAT instance). – Michael - sqlbot Dec 31 '13 at 19:20
0

Another option is VPN or DirectConnect connection. If you create VPN or DirectConnect connection to you vpc from your corporate network, then you will be able to access all the resources from the corporate network.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.