I have 3 machines and may have more later on. 1 machine act as load balancer while the other 2 contain same website files and database. Most of the CPU usage is on mysql so I have to separate database in 2 machines in order relieve the load.
The structure would be like:
Each time when I update the website. I will trigger an update.php which write something into the database. But because of the load balancer. Some data was written into aaPanel 2 while some was written into aaPanel 3. Thats why I would like to create a "Master-Master sync" between aaPanel 2 and 3.
As the traffic of my websites grow suddenly recently. And I am new to this area. If this structure is not good for future development. It is my pleasure to hear your advise. Thank you in advance.