• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How mirror database

#1
Hi
I have a site that i publish many post into it
Now i need i have this project on other host for when if first domain disabled so switch to second domain
So i need sync database with together
The sync files is easy
But what is way to sync database?
Reply

#2
@omid_student,

Are you trying to do this through a hosting company? Do you have full access to the database (to change the configuration). Replication seems to be the direction that you are heading in. I don't know if you will be able to do this with a hosting database. You might have to talk to the hosting company to see what you can do.
Reply

#3
(09-17-2019, 05:12 AM)php_rocs Wrote: @omid_student,

Are you trying to do this through a hosting company?  Do you have full access to the database (to change the configuration).  Replication seems to be the direction that you are heading in.  I don't know if you will be able to do this with a hosting database.  You might have to talk to the hosting company to see what you can do.
I use host and cannot access to configuration
So i tell hosting company this problem

OOO if i have VPS,for mirror database i have to use Replication?
Reply

#4
@omid_student,

You can use replication which will keep the master and slave databases in sync or you can use the manual process which is every create/update/delete query is tracked and sent to multiple databases simultaneously.

Replication: https://www.toptal.com/mysql/mysql-maste...n-tutorial
Manual process is not the ideal solution but it does work if maintained.
You could also consider a cloud based database which should have the replication process built in which should be easy to turn on.
Reply

#5
(09-17-2019, 07:57 AM)php_rocs Wrote: @omid_student,

You can use replication which will keep the master and slave databases in sync or you can use the manual process which is every create/update/delete query is tracked and sent to multiple databases simultaneously.

Replication: https://www.toptal.com/mysql/mysql-maste...n-tutorial
Manual process is not the ideal solution but it does work if maintained.
You could also consider a cloud based database which should have the replication process built in which should be easy to turn on.
Thank you so much Heart
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.