LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 07-25-2013, 02:29 AM   #1
circus78
Member
 
Registered: Dec 2011
Posts: 273

Rep: Reputation: Disabled
Question about MySQL replica


I had a MySQL Master-Slave configuration.
The master had a physical failure, and it has been shut down for several days.
In the meantime I changed ip of slave server with the master, and I used the command "stop slave".

Now the master has been repaired, my doubt is: it's better to move the original master configuration (my.cnf) to slave, in order to make slave the new master?
Or should I export all databases from the slave to the master?
 
Old 07-30-2013, 03:17 AM   #2
SAbhi
Member
 
Registered: Aug 2009
Location: Bangaluru, India
Distribution: CentOS 6.5, SuSE SLED/ SLES 10.2 SP2 /11.2, Fedora 11/16
Posts: 665

Rep: Reputation: Disabled
Quote:
Now the master has been repaired, my doubt is: it's better to move the original master configuration (my.cnf) to slave, in order to make slave the new master?
Could be a better idea but replacing configuration is not that only required you have to grant replication_master permission to the slave(new master) and configure other options as well those are configured for master while replacing them with the new slave(current master).

On the other Hand if you export all databases from slave to master you can just revert back the ip of the master and "start slave".
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] sync/replica mysql from 1server to another centos123 Linux - Server 4 08-01-2012 02:47 AM
replica of server bkcreddy17 Linux - Newbie 4 04-16-2008 10:28 AM
Mysql master and replica over VPN Vitalka Linux - Networking 1 10-04-2007 07:40 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:50 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration