Web server is down Error Code 521

0

Hi,

My website was working perfectly but suddenly i see this error when trying to access it. I have tried accessing it through the public ip but still wasn't able to connect. I tried accessing it with ftp but it says failed to connect to the server.

I'm on the aws free tier and installed bitnami wordpress.
I'm using cloudflare for cdn & ssl.

I'm new to AWS please help.

daanish
asked 6 months ago231 views
1 Answer
0

Hello.

Is the AWS service you were using EC2?
If it's EC2, did you do anything like stop EC2 before the problem occurred?
If EC2 is stopped, the public IP address will change, so please check whether the IP address set in CloudFlare is correct.
Also, if the cause is to change the IP address, I think it is also effective to set an Elastic IP address.
https://repost.aws/knowledge-center/ec2-recover-ip-address

profile picture
EXPERT
answered 6 months ago
profile pictureAWS
EXPERT
reviewed 5 months ago
  • Yes, i'm using EC2 and i haven't stopped the instance or made any changes to it. The public ip on my ec2 instance and cloudflare match each other. Before this issue, i was setting up a cache plugin on my wp site and optimizing the images. Here's my public ip - https://15.228.234.124/ The website url - https://mrsocialdigital.com/

  • When I run the curl command, the following error occurs. From this, I suspect that a web server such as Apache is not running on EC2.

    curl https://15.228.234.124/
    curl: (7) Failed to connect to 15.228.234.124 port 443: Connection refused
    
    curl http://15.228.234.124/
    curl: (7) Failed to connect to 15.228.234.124 port 80: Connection refused
    

    Connect to EC2 using SSH or Systems Manager Session Manager and check if the web server is running.

  • I tried connecting through SSH i get this error "server refused our key no supported authentication methods available server sent public key" I followed the instructions to connect to putty mentioned here - https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/putty.html

    I also tried connecting through Ec2 Instance Connect and i get this following error "Failed to connect to your instance Error establishing SSH connection to your instance. Try again later."

  • Should i try rebooting the instance?

  • Please also try connecting with the SSH client below. https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/connect-linux-inst-ssh.html#connect-linux-inst-sshClient

    ssh -i /path/key-pair-name.pem instance-user-name@instance-public-ip-address
    

    If it still doesn't work, try restarting.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions