Wordpress not working after changing instance type on Google Cloud Platform - wordpress

I changed my VM instance from "F1-micro" to "E2-micro". When I then restarted my machine, I couldn't access my webpage using the domain name, the webpage just shows an "Error 521" code - showing that my browser is working, CDN is working but the host has an erorr. When I paste the VMs IP address into my webpage, however, it show's the "Apache2 Debian Default Page".
Can somebody please help me with this?

The Error 521 message is caused by one of two situations:
First, check whether your WordPress site’s server is down. Even if everything else is configured properly, if your WordPress site’s server is offline, Cloudflare simply won’t be able to connect.
Second, your web server might be running fine but blocking Cloudflare’s requests. Because of how Cloudflare works, some server-side security solutions might inadvertently block Cloudflare’s IP addresses.
Cloudflare is a reverse proxy, all the traffic coming to your origin server will appear as if it’s coming from a small range of Cloudflare IPs (rather than each individual visitor’s unique IP address). Because of that, some security solutions will view high traffic from a limited number of IP addresses as an attack and block them.
Please check this link out in order to fix error 521 for Cloudflare and WordPress.

Turns out this problem was caused by my having installed the Debian Apache server package and it is causing collisions between it and the Apache shipped in the stack. Bitnami Stacks are completely self-contained and run independently of the rest of the software or libraries installed on your system.
So to fix this, all I had to do was run the following commands:
sudo systemctl stop apache2
sudo /opt/bitnami/ctlscript.sh restart

Related

Google Cloud Hosted VM. This site can’t be reached <URL> refused to connect

Forgive me here, I am largely post-technical for 10+ years and taken this as far as I can. I can probably take any advice and run with it, but may ask for some specifics to help if troubleshooting tools or commands are required. So please forgive that too.
Background:
Yesterday we could hit site URL after restarting VM hosted on Google Cloud. Sometime overnight, the URL was inaccessible.
Message:
This site can’t be reached <URL> refused to connect.
Try:
Checking the connection
Checking the proxy and the firewall
ERR_CONNECTION_REFUSED
Troubleshooting:
can load using IP.
The technical guys (3rd party suppliers) insist they have not made any changes. My team have not made any changes.
The domain is still valid (it renews tomorrow)
The domain is used for the DEV environment with DEV as a prefix hosted on another VM.
Looking at firewall rules, all the rules with the proper tags appear to be set up correctly for HTTPS with appropriate IP (0.0.0.0) and port 80.
Many thanks in advance for your help. When I find the answer, I will post it here.
RESOLVED:
ROOT CAUSE:
During setup on GCP, the team forgot to link the reserved external IP address to the VM. As such, the external IP address was ephemeral so after a reboot of the server, Google issued a new external IP for the VM.
SOLUTION:
Reserve a static external IP Address and link it to the VM or promote an existing ephemeral external IP Address.
https://cloud.google.com/compute/docs/ip-addresses/reserve-static-external-ip-address

DNS_PROBE_FINISHED_NXDOMAIN on loading my WP app

I have hosted my WP app in AWS EC2 and is using GoDaddy DNS to point it to my domain. I received and email from GoDaddy stating that my site is blacklisted by McAfee as Malicious. Please see the image:
Now, when I try to access my website Google shows an error page with the following content : DNS_PROBE_FINISHED_NXDOMAIN. Is this because my site is blocked due to the McAfee blacklisting. Any help on this is highly appreciated, Thanks in advance.
DNS_PROBE_FINISHED_NXDOMAIN means that your domain is no longer pointing to your server.
to troubleshoot you may use these steps:
check your domain resolve status via this tool https://dnschecker.org
if NOT resolved at all register a Cloudflare account then change name servers in your registrar panel to NS provided by cloudflare.
make sure that all DNS entries are like original zone.
wait for propagation and recheck https://dnschecker.org
restart your home router and run this command on windows CMD ipconfig /flusdns
if you are on Debian/Ubuntu run sudo /etc/init.d/networking restart
You can try below solution to fix DNS_PROBE_FINISHED_NXDOMAIN issues.
Release and Renew IP Address
Restart DNS Client Service
Change DNS Servers
Reset Your Browser
Disable VPN and Antivirus Temporarily
try this post for complete info:- DNS_PROBE_FINISHED_NXDOMAIN

Creation of AMI from operating wordpress site yield "connection refused" with elastic ip

I created an AWS server and installed wordpress with an elastic ip address and verified that the default website was up and running.
I wanted to make a backup image at that point so that I could use it as a beginning point for other websites. However, after getting the AMI running and attaching the elastic ip address to it, I got an "connection refused" error. I can both SSH and FTP into the server, but the wordpress site is offline. I then switched the elastic ip back to the original server and got the exact same issue.
I'm guessing that this is a "change of ip" type error(?) (although, when I've seen that before, the connection has never been outright refused... it usually allows at least access to the admin area of the website) but I thought by using an elastic ip address that I would avoid that. I'm also confused by the error in the first server, since the database still has that address.
Any ideas about how to troubleshoot something like that? Is there anything else that it could be?
Well.... I missed something vital.
Using an AMI works just fine with an elastic ip address. I had forgotten to make sure the webserver (httpd) and mysqld were running with :
service httpd restart
and
service mysqld restart
What made it click was reading that the main reason for this error is that there is listener to the incoming data.
Duh.

R httpd issue - help pages fail to load using local IP

This may be a general topic, but I came across the issue while working on some code using the Rook package.
The recent R versions include an http server. You may have seen this while checking for help topics using RGui. It opens a new browser with the IP/Port, etc.
For eg., if I enter ?paste, this brings up,
http://127.0.0.1:31234/library/.../paste.html
But if I use my IP, say 192.168.1.2 in place of 127.0.0.1, the page fails to load, I get an error
While trying to retrieve the URL:http://192....
The following error was encountered:
We can not connect to the server you have requested
I have other apps that have httpd interfaces, and I can go to those app's http interfaces using both 127.0.0.1 and 192.168.1.2 ... etc. So, as far as system/network permissions are concerned - I do not think that is the issue here.
Rather, there is something specific to the R httpd process that disallows it to be accessed using the domain name, etc ?
The above was tested in a corporate network. When I tried the same process from my home network it worked fine. However, since I already access http interfaces of many other locally installed apps from the corporate PC, I think there might be something specific to R's http process that needs to be checked ?
Workstation is running - Windows XP
Please let me know if you have any thoughts on the above,
Regards,
Raj.
Fixed it. The trick is to specify,
s <- Rhttpd$new()
s$start(listen="0.0.0.0",port="20000")
when starting the Rook process. Specifying 0.0.0.0 makes it listen to all the interfaces and now I can access it using my external IP. Thanks a lot for your help nonetheless !
When opening a TCP port, the local IP address may be chosen. For incoming connections, typically INADDR_ANY (-1) is supplied to bind(), which means to open the port on every available interface.
However, it is quite possible to open a port on just one interface on your machine (in this case, 127.0.0.1), simply by supplying the IP address of the interface. Seems that R does just this.
My guess is that you may have a proxy in place on your corporate network. Your browser is probably configured to use that proxy to access the Internet. Most browsers will exclude an address which they know to be local (127.0.0.1 or localhost) from using the proxy, but might not exclude any other IP.
Try disabling the proxy in your browser (even "Auto-Detect", completely turn the proxy off) and see if you're able to connect.
I had the same problem.
If you are using RStudio, this might be a bug in the RStudio. Check out this link:
https://support.rstudio.com/hc/communities/public/questions/202656007-Cryptic-error-on-starting-RStudio-daily-with-R-devel
Updating to the latest version of RStudio with the latest version of R fixes the problem.

Why can I see my website even though it's down?

I'm wondering if anyone knows how this happens? My website is down, but every computer on my internet connection/router can see it. I've cleared my cache etc, but another computer in the house shouldn't be seeing a site that's offline. How weird?
It's hosted remotely, not on my network or anything.
The first question to ask yourself is, how certain are you that it's down? If computer A can access it and computer B cannot, either one could be "right":
The site could be down, and computer A could be looking at a cached version from the ISP.
The site could be up, but computer B could be having general internet connectivity problems, or problems accessing this site in particular (bad DNS cache, etc.)
One way to tell is to add some new content to the site (via FTP or an in-place content management system like wordpress, for example) and see if the computer that can access it (computer A) can see the changes. If so, then you're looking at a "live" site, where the pages are being served directly from the server. (If the server is active and runs web software like PHP or ASP, then that would be another way to "prove" that the site is up and running).
Do you know the IP address of your web server?
Do you have direct access to the Internet on port 80?
Tell if your server is up or down by doing the following
telnet 255.255.255.255 80
Where 255.255.255.255 is your web server's IP address. On windows the screen will go blank if the server answers. Then type
GET / HTTP/1.0
And hit enter twice. You should see the content of your default page. If your running as a virtual host, you'll probably need to use HTTP/1.1 and the Hostname tag.
GET / HTTP/1.1
Host: www.yourservername.com
There is one return after HTTP/1.1 and two returns after your hostname. If you get content (the correct content) back from your web server it is definitely not down. If the server fails to connect then your web server is really down, and the content your computers are seeing could be any of the following:
local page cache
local proxy server
ISP proxy server
local ARP poisoning attack redirecting you to attacker's local web server which mirrored your site.
DNS poisoning to direct your browsers to someone else's web server which mirrored your site.
If your site is up, but geographically separated folks can't see your site, it is most likely a DNS issue or an ISP level routing issue.
A good tool to check for DNS issues is OpenDNS's CacheCheck. As for the routing issue, the best bet is to call your web hosting company and see if they've had any other complaints from their other customers, or if they are currently working on a routing issue.
Internet provider cache maybe.
What DNS servers are your friends using? Same as yours?
Your ISP is probably caching the content.
i know it's down cause i asked my friends in other locations to look at it. then i ran a test using this site i found.
http://www.websitepulse.com/help/tools.php
i'm switching hosts and we're dealing with my main domain name. that's the other reason i expected this interuption. i just want to know when it's finally switched.
is ISP cache a bad thing?

Resources