Hi,
I'm currently creating a website for a social project in switzerland.
And before there is an overflow of user, I want to prepare the application to scale.
I answered by myself many questions but some are left.
I explain what I want to do.
First
at the beginnning, the Application will have only one server (short time) with DNS, PHP, Mysql, Data, and memcache.
Second
Then I will split them in two
- DNS, Mysql, memcache
- Data, PHP
Third
Here is the problem, I don't know how to do it exactly here to keep the application running well.
I could do :
- Front : Load Balancer, memcache, DNS
- Web 1 : PHP, DATA
- Web 2 : PHP, DATA
- Mysql
This would be the scheme, all PHP sessions are kept in the DB.
BUT, how do I sync the data? do I run a Rsync to keep them up to date. do I put them on a separate disk (network disk) to be sure ? but in this case, how can I do in case of user uploads ?
and if the website gets more success and we have to go on greater structures, would'nt it create some latency on updates ?
or would it be a good thing to go directly to amazon's web services ?
some infos I use codeigniter as Framework. I use linux as webserver (distribution not chosen now, but should be Debian)
Thanks in advance for your answers.