Hello, I am in the process of transferring a wordpress that was previously hosted on wamp on my home server, on to digital ocean. I am reciving an error on every page that simply says “can’t reach this page” on microsoft edge and chrome says ERR_CONNECTION_TIMEOUT
I followed the procedure here https://codex.wordpress.org/Moving_WordPress I imported the old database, and I have made sure that the username and password match in the wp config file. I am stumped as to what else might be causing the problem, any suggestions would be appreciated and I can certainly provide a lot more information, I just don’t really know what is needed.
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Click below to sign up and get $100 of credit to try our products over 60 days!
In general, it’s a very bad idea to hack up your wp-config.php + way better to fix your runtime environment so your install simply works.
First get everything working with pure Apache (remove NGINX).
Steps…
Use netstat -pluten to ensure apache is really listening on port 80 + 443.
If Apache is truly listening + setup correctly, you should see the Apache default page for non-SSL (port 80) access. Fix this before proceeding.
Setup your Apache config + run apachectl -t + ensure you get an OK before proceeding.
At this point you should have your WordPress root directory serving.
Deploy your WordPress installation via backup restore or wp-cli or however you do it.
All should be well.
@tommyconner96
The error log definitely doesn’t help in this case as all that’s showing is that Apache was restarted.
Is this the only site on the Droplet? If so, and there’s only one Apache VirtualHost setup, can you try to change the URL on the WordPress site to the IP of your Droplet and see if you’re able to access it?
Inside of
wp-config.php
, add the following:Replace
http://example.com
with your Droplet IP. For example, if you’re Droplet IP is:You’d use:
That’ll make it so that WordPress responds by IP instead of by domain. If that works, then the issue is either related to your VirtualHost configuration or it’s a DNS issue.
We’d then need to take a look at your VirtualHost file, your DNS, or both. You’d generally get an error relating to DNS in Chrome when DNS is not correctly setup, so the issue may very well be with the VirtualHost.
If you can paste that in to a response using a code block (to ensure proper formatting), I’ll be more than happy to take a look at it for you.
@tommyconner96
The error itself doesn’t say much about what’s going on, so we’d need to check the error logs to see if there anything showing up there first and foremost.
If you’re using Apache, we can get the last 20 lines using:
If you’re using NGINX, we can get the last 20 lines using:
If you can paste the output of either command (whichever server you’re running), we can see if the logs are able to tell us anything.