By sivaprasath
Currently, I’m doing with same DB name. I’m planning to have centralized DB replication for 3 servers. but the problem is the name of the database in all servers is same.
Can we replicate to slave with different name as shown below?
Master database to replicate : abc
Salve database: abc_1
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
You should technically have the database name be the same, because the database is replicated it is an exact copy so you want to make sure that the naming remains consistent. I’m not 100% sure if you can even replicate it with a different name, as I’ve never really seen that request before. Not sure what the reasoning for using a different name would be.
You instead use the hostnames of the different DB servers to designate which one is the master, and which ones are the replicas, as well as of course the configuration of the DB itself which specifies that.
But you want to confirm with standard practices to ensure that everything works smoothly, so I would recommend to not switch the database names.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.