- 最新
- 最多得票
- 最多評論
Hi there
A simple curl request shows us that the instance is not accessible on port 80 (HTTP)
curl burhanidigital.com
curl: (7) Failed to connect to burhanidigital.com port 80: Connection refused
Connection refused means that something is blocking the incoming request (my curl command). Each EC2 Instance has a firewall. In Lightsail this can be viewed in the instance "manage" menu. This menu has a "Networking" tab. Check the "IPv4 Firewall".
By default it should have:
Ensure your firewall matches the screenshot for HTTP and HTTPS.
If the issue persists connect to the instance and confirm the web server is running. This will likely either be Apache or Nginx. Check if the instance is listening on port 80 with this command,
netstat -tulpn
If you dont see 80 and 443 like below this is the problem.
To resolve that you will need to start the web server. This will vary depending on the platform and blueprint you have chosen. As an example, if you chose linux and wordpress you can start apache using bitnami with this command:
sudo service bitnami start apache
The bitnami docs go into more detail here [1]. If the issue persists let us know what platform (linux/windows) and blueprint (wordpress, ruby, node) you've chosen.
My 443 port was missing, however, this answer got my instance up an running in seconds. Thank you Cormac C.
Hello,
It's hard to troubleshoot this without knowing more information.
- Was this created using an existing application Blueprint such as Wordpress, Drupal, Joomla, or Magento?
- Was this created using a standard Linux blueprint with a web server like Nginx or Apache?
Ensure that the web server is up and running and the configuration is valid.
Apache restart
sudo service apache2 restart
or
sudo systemctl restart httpd
Nginx restart
sudo service nginx restart
or
sudo systemctl restart nginx
If either of these fails to restart, you may have an error in your configuration or your instance may be out of storage space. Try researching the error by searching re:Post or Google.
相關內容
- AWS 官方已更新 3 年前
Issue resolved, thanks for the help :)