Can't browse to my EC2 Instance

apache amazon-ec2 cloud

25264 просмотра

3 ответа

5752 Репутация автора

I've just (about 1 hour ago) associated an Elastic IP to my instance at Amazon EC2. If I SSH into my instance and type lynx localhost I can see that apache is responsive because I see the It works page.

However, If I browse into my instance (both via the IP itself and via the public DNS Amazon has created for me), I get Oops! Google Chrome could not connect to.. bla bla...

Should I wait some more time (in case it's due to some DNS thing) or does this indicate something is wrong?

Thanks in advance

EDIT: When I ssh into my instance, I use the full IP address and it works... (the Elastic IP I mean).

Автор: Felipe Almeida Источник Размещён: 10.03.2012 10:45

Ответы (3)


36 плюса

14956 Репутация автора

Решение

You must config the firewall to open the HTTP port.

To be more specific, for AWS this is done via Security Groups. You should create one with the ports you need opened. In most cases that's the por 80 for TCP.

You can see how to achieve this on the documentation http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html

Автор: Ismael Abreu Размещён: 10.03.2012 11:02

17 плюса

4497 Репутация автора

  • First identify the security group of the Ec2 instance.
    • Next click on the security groups link in the bottom left nav.
    • Select the security group under which this EC2 instance lies, and add Inbound rules by specifying the port or a custom port range.
Автор: Sangram Anand Размещён: 12.03.2012 05:42

0 плюса

597 Репутация автора

For those of you using Centos (and perhaps other linux distibutions), you need to make sure that its FW (iptables) allows for port 80 or any other port you want.

See here on how to completely disable it (for testing purposes only!). And here for specific rules

Автор: nsof Размещён: 21.05.2013 02:24
Вопросы из категории :
32x32