Hey all!
We’ve been getting quite a few inquiries on how to go about adding a WordPress site on a couple of servers, behind a load balancer, and connected to a database on a separate server.
So, I’ve added a guide to help provide some pointers!
The first method has some manual, duplicative steps. However, I’m confident it will get easier over time as some of our road map items, such as cloning databases and sites, should be of good helpful use.
The second method uses WordPlate, which is convenient in a lot of ways and makes setting up a WP site behind a load balancer more convenient in several ways. There are other similar options like WordPlate out there as well if this one doesn’t work for your needs. Just wanted to provide it as an option.
Nice guide, thanks for this.
I have one concern and that is about the local (static files).
You can have in WordPress database records for your media files even if the don’t exists. But in the backend they doesn’t show up. A CDN solves the problem for the visitor, but not for the site owner.
Example: The image was uploaded on the second balanced app server and I need to change a post on the first server. In this case the image doesn’t show up because it doesn’t exists on that server right?
Much better is to keep both balanced server in sync with rsync or some other tool.
Both media plugins you’ve suggested are nice solution for off-loading your media, but they doesn’t feature this for load balancing. I didn’t build my own cluster yet, but I remember me some troubles whenever using a CDN.
With the plugins I looked at, the plugin would need to be installed on each server. From there, you can upload the image on one server, it will store on the external storage system, then the plugin will pull the image from the external storage no matter which server a visitor is actually on.
They seemed to be working well for me - but may not be for everyone. There were a few bad reviews on the plugins, but they didn’t seem to say what the problems were (other than not getting support for the pro versions - which would be frustrating).
I’ll try a filesystem sync solution later this week and will add to the guides (assuming I get them to work ).
I will try both options (if I find the time)
1 Like