Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My setup for my website is that i have a load balancer server, and two lamp servers and on the two lamp servers i have phpmyadmin installed.

I have synced the two lamp servers /var/www folders with unison and work perfectly..

What i am wanting to know is or does anyone know how to synchronize phpmyadmin database for the one website( As this whole setup is for 1 website only..)?

because i use the Load balancer server to direct traffic to either server and the website is on both lamp servers... Just want to know is there a way that i can synchronize the databases as i am using phpmyadmin or can it be done that the 1st lampserver is configured to the phpmyadmin installed on there and that the 2nd lampserver can connect to the 1st lampserver's phpmyadmin is that possible?

first machine: zen load balancer (server) second machine: lampserver (webserver1) holds the website files that sync with webserver 2 third machine: lampserver (webserver2) holds the website files that sync with webserver 1

or should i create another machine that just has phpmyadmin on it and holds the database for website directing the two lamp servers to connect to this machine?? How can this be done??

any help would be much appreciated..

all servers except zen load balancer are running ubuntu 12.04 lTS server OS

share|improve this question

Because each LAMP server is running its' own instance of MySQL, phpMyAdmin running on either server will only connect to the local MySQL instance on that machine. It's possible to set up MySQL to have server replication (master to slave) and for that you would have to delve into the MySQL manuals for setting that up. That would keep the databases synchronized and phpMyAdmin on either server would display the same database information (relative to the timing of the MySQL server replication process).

The other option is to use a single MySQL server to serve your databases and have regular backups set for the MySQL data.

share|improve this answer
i understand thanks for the information i will look into it – user161690 May 25 '13 at 19:25

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.