Bug #49197 | MySQL SwitchOver mechanisam not works. | ||
---|---|---|---|
Submitted: | 30 Nov 2009 8:38 | Modified: | 1 Dec 2009 6:57 |
Reporter: | Amit Bora | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 5.1.34 | OS: | Windows |
Assigned to: | CPU Architecture: | Any |
[30 Nov 2009 8:38]
Amit Bora
[30 Nov 2009 9:31]
Sveta Smirnova
Thank you for the report. This looks like not a bug, but wrong setup for me. Do you have option log-bin in x.x.x.x configuration file? What shows SHOW SLAVE STATUS\G running on y.y.y.y after switch?
[30 Nov 2009 9:38]
Amit Bora
This is the output after I executed the below steps: mysql> show slave status \G *************************** 1. row *************************** Slave_IO_State: Waiting for master to send event Master_Host: x.x.x.x Master_User: slave_user Master_Port: 3306 Connect_Retry: 60 Master_Log_File: .000013 Read_Master_Log_Pos: 106 Relay_Log_File: ps4743-relay-bin.000009 Relay_Log_Pos: 242 Relay_Master_Log_File: .000013 Slave_IO_Running: Yes Slave_SQL_Running: Yes Replicate_Do_DB: mysql_repl Replicate_Ignore_DB: Replicate_Do_Table: Replicate_Ignore_Table: Replicate_Wild_Do_Table: Replicate_Wild_Ignore_Table: Last_Errno: 0 Last_Error: Skip_Counter: 0 Exec_Master_Log_Pos: 106 Relay_Log_Space: 398 Until_Condition: None Until_Log_File: Until_Log_Pos: 0 Master_SSL_Allowed: No Master_SSL_CA_File: Master_SSL_CA_Path: Master_SSL_Cert: Master_SSL_Cipher: Master_SSL_Key: Seconds_Behind_Master: 0 Master_SSL_Verify_Server_Cert: No Last_IO_Errno: 0 Last_IO_Error: Last_SQL_Errno: 0 Last_SQL_Error: 1 row in set (0.00 sec) mysql> RESET MASTER; Query OK, 0 rows affected (0.11 sec) mysql> show master status \G *************************** 1. row *************************** File: ps4743-bin.000001 Position: 208 Binlog_Do_DB: Binlog_Ignore_DB: 1 row in set (0.00 sec)
[30 Nov 2009 10:46]
Sveta Smirnova
Thank you for the feedback. You have Replicate_Do_DB rule, probably this matters. Please send us binlog which was not replicated.
[30 Nov 2009 13:08]
Amit Bora
Trying to insert recoed which is not replicated to slave(y.y.y.y)
Attachment: BinLogFile_NotReplicated.zip (application/x-zip-compressed, text), 440 bytes.
[30 Nov 2009 13:10]
Amit Bora
Trying to insert record which is not replicated to slave(y.y.y.y)
Attachment: .000001 (application/octet-stream, text), 206 bytes.
[30 Nov 2009 13:17]
Amit Bora
I am not understood the way I need to follow. I will explore What I am doing. 1. I have setup working as Master - Slave both side bin--log is created. 2. I shutdown the Master Server. 3. Running the command on Slave (x.x.x.x) as STOP SLAVE -> RESET MASTER. 4. starting y.y.y.y (Master) -> STOP SLAVE -> CHANGE MASTER TO MASTER_HOST='x.x.x.x', MASTER_USER='slave_user', MASTER_PASSWORD='password'; Is this the correct way of changing the master(when gets up) to become a slave? I don't made any changes in my.ini file of both. Kept as it is with initial setting done. Down it matters?
[30 Nov 2009 13:36]
Sveta Smirnova
Thank you for the feedback. Binary log file is correct and should be replicated having information provided. But you have "Master_Log_File: .000013" in SHOW SLAVE STATUS while sent file named ".000001" Also you issued MASTER_LOG_FILE='.000003', so it is expected log file .000001 is not replicated. Please check if this is just wrong names you sent to us or you really mixed these logs.
[30 Nov 2009 13:54]
Amit Bora
I think Meanwhile I done RESET MASTER so previous log is deleted. Please have a look into the attached file for info.
[30 Nov 2009 13:54]
Amit Bora
New configuration information.
Attachment: CommandLog.rtf (application/rtf, text), 5.12 KiB.
[30 Nov 2009 13:55]
Amit Bora
Binary Log
Attachment: .000002 (application/octet-stream, text), 306 bytes.
[1 Dec 2009 6:55]
Amit Bora
At Last I came to know that I have not created user on SLAVE(which is now master) machine to replicate data on master(which is now slave of slave). The problem is solved. Thanks for the prompt reply each time.
[1 Dec 2009 6:57]
Sveta Smirnova
Thank you for the update. Closed as "not a bug".