0
votes

I have Node.js installed on a RedHat instance of EC2. I also installed Express and am trying to run 'node app.js'. I get the console message that it's listening on port 3000. I try to navigate to http://.compute-1.amazonaws.com:3000/ but nothing shows up. I tried to change it to 8080 and nothing as well. I have all these ports in my security group (TCP 3000, SSH 22, TCP 8000, TCP 8080). Not sure why this isn't working! Is it something with RedHat?

Any help is appreciated. Thanks

2

2 Answers

2
votes

There is a high chance your instance comes with an active firewall.

do: iptables -L

it should list your current firewall status.

Then, depending on your redhat linux version, will have to configure the firewall to open the ports. (See redhat documentation or http://www.cyberciti.biz/faq/rhel-fedorta-linux-iptables-firewall-configuration-tutorial/)

0
votes

In the future check your security group you assign when you create the EC2 instance. You can modify this group after the fact but you cannot assign a different group. Make sure port 3000 is open.