I'm doing some research for a project I'm working on, and I'm a bit stumped as to what to do when it comes to load balancing and mpm-itk.
I currently have a web server (webA) running apache2-mpm-itk, which stores the user files in /sites/<sitename>
. So, if I hit www.siteA.tld
it pulls from /sites/siteA
and runs as user siteA.
This works fine for a single server, but if I now put haproxy in front, and direct to webA and webB, only the requests that hit webA work. (Obviously, as I haven't synced the boxes yet.)
The question is, what's the best way to sync these machines?
- Use rsync to sync the
/sites/*
folder? (But what about user accounts??) - Use NFS to store the
/sites/*
folder, and just sync the users somehow? - Some other cool way that works much better with mpm-itk?!
I guess what I'm really after is how to keep the user accounts synced so that mpm-itk still works on either box.
Edit: It doesn't have to be mpm-itk, but any way that I can run apache as separate users, load balanced, and keep the user accounts in sync between multiple machines.