Common REST errors
Important: From version 1.8.0 and going forward, REST services are no longer used by WP Synchro.
REST errors are the most common error we see and also the reason for most support issues.
This is fairly
natural and expected as all communication are done via REST services.
These errors can be seen in the synchronization log files and will look something like this, where you can spot the http error code (marked with bold):
[2019-08-08 05:38:58.969529] [DEBUG] Got error connecting to service https://example.com/wp-json/wpsynchro/v1/populatefilelist/?token=<token> with http code 401 - Retry 1 of 10
In the above case, the error is a HTTP 401 error.
Next up, we go through some of the most common error codes and what to do about it:
HTTP 401 - Unauthorized
This the most common HTTP issue we see when using WP Synchro. The error means that a request was unauthorized. It can be caused by multiple things. Make sure to check the synchronization log for further information on the HTTP 401 errors, as it may contain valuable insight into where the error comes from.
The most common causes are:
- Security plugin, like WordFence blocking requests
- For WordFence, other customers have reported that putting it in "learning mode" fixed the problem
- For other security plugins, try disabling them for a moment, to see if they are the reason
- Multi-server/cluster environments on one of the ends of the synchronization
- See our guide on multi-server/cluster environments
- Plugins that blocks/disables the WordPress REST system
If the above solutions does not solve your issue, feel free to contact WP Synchro support.
HTTP 403 - Forbidden
This is almost never related to either WordPress or WP Synchro. This is most likely errors thrown directly by the web server, without ever touching WordPress or WP Synchro. You should look for a misconfiguration in the web server, such as .htaccess files for Apache that are incorrect. Contact your hosting or developer to get help with this.
Web server security such as mod_security has been seen flagging the REST requests as malicious, aka a false-positive. Your hosting can help you determine if this could be the case.
HTTP 500 - Server error
These errors can be cast when some error happens at the server and it can not continue. This can be PHP errors or error from the web server. You should start by checking your PHP error log on your hosting and see if anything WP Synchro related is in there.
If you see PHP errors related to WP Synchro, you should contact WP Synchro support.
If you don't see any errors in the PHP error log, you should look towards the web server. We have seen web server security like mod_security creating false-positives because of the nature of a database/file synchronization. You should contact your hosting and tell them you are experiencing HTTP 500 errors on the urls from the log. This will help your hosting support team identify if their setup are responsible for these errors.
Lastly, we have seen servers throw HTTP 500 errors that seem random in the log files. So if multiple synchronizations generate HTTP 500 errors in different places and seemingly random, it is probably a stability issue. You should contact your hosting to get this resolved.
Still using free version? - Upgrade to PRO with 14 day free trial
PRO version makes it possible for you to migrate files between your sites and to
automatically make a database backup before migration.
You will get support for Basic Authentication and email notifications on success or failure. You also get access to priority support