On Tuesday 17 June 2003 03:35 am, George Chelidze wrote:
> Hello,
>
> I have two RH boxes with mysql on them and replication is enabled from
> box 1 to box 2 and from box 2 to box 1. The amount of data on each of
> them is round 400-500MB. Now I have to replace one of them with new box.
> As both boxes are productional ones, I'd like to replace one of them
> online without stopping them. I know I can tar the tables (MyISAM) and
> move to a new box but I have to make sure the data won't change, so I
> have to offline the boxes. Is there any way to do this replace
> transparetely? Any recommendations would be great. Thanks in advance.

For replacing box 1:

1.  Direct requests to box 2 
2.  Stop slave on box 2
3.  Record log file and position on box 1 using show slave status
3.  Stop mysql on box 1
4.  Move tables from old box 1 to new box 1
5. On new box 1, run CHANGE MASTER TO MASTER_HOST='<master host name>',
 MASTER_USER='<replication user name>',
 MASTER_PASSWORD='<replication password>',
 MASTER_LOG_FILE='<recorded log file name>',
 MASTER_LOG_POS=<recorded log offset>;
filling in box 2's name, and the log name and position recorded in step 3.
6.  Start slave on box 1.
7.  Start slave on box 2.
8.  Verify box 1 looks ok
9.  Direct requests to both boxes again.

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to