Home >Backend Development >PHP Tutorial >If you want to keep the root directory of the website on 20 servers consistent (such as load balancing), how do you keep the files updated synchronously? The more detailed the better
If you want to keep the root directory of the website on 20 servers consistent, how do you keep the files updated synchronously?
If you want to keep the root directory of the website on 20 servers consistent, how do you keep the files updated synchronously?
It must be a distributed file synchronization system. Generally, simple operations will have problems. The one mentioned above is fine
The oschina git I use has a web hooks function when you push code to the server. The git server will request the URL address you specified. At this time, you can execute system commands on that URL to update (please pay attention to security issues)
rsync?
rsync
NFS, directly mounted on multiple machines
inotify rsync
ansible
svn/git
ansible