Thursday, 12 September 2013

Shared upload folder between multiple wordpress servers

Shared upload folder between multiple wordpress servers

I have a wordpress blog which is replicated, i.e. 2 servers behind load
balancer serve the same wordpress blog. I pointed the database on both
servers to the same database so I have no problem there. However, when a
user is forwarded (by the load balancer) to server-1 and uploads files,
they are kept on server-1. The same goes for server-2. Those files are not
shared between the 2 servers and therefore user who is forwarded to
server-2 will not see the files (e.g. images) which were uploaded to
server-1.
I read that the upload folder can be changed but "This path can not be
absolute. It is always relative to ABSPATH".
What are the best practices to share the upload folder between servers?

No comments:

Post a Comment