MySQL Forums
Forum List  »  Replication

Show master status log position
Posted by: AASHISH KATARIA
Date: June 30, 2015 12:19AM

Hi,

We have added 1 more schema to the existing Database. We have to set up replication for 2 schemas now( earlier only 1 was being replicated ). If i run the command show master status by using the use database command, i get different log positions for the binary log file. And if i don't use the use database command, then the log position is differnt than the two. So which log pos should i use when configuring the replication on slave ? Below are the different outputs :

mysql> show master status;
+------------------+----------+----------------+------------------+-------------------+
| File | Position | Binlog_Do_DB | Binlog_Ignore_DB | Executed_Gtid_Set |
+------------------+----------+----------------+------------------+-------------------+
| mysql-bin.000198 | 56956849 | cctns_state_db | | |
+------------------+----------+----------------+------------------+-------------------+
1 row in set (0.00 sec)

mysql> use cctnsext_state_db;
Database changed
mysql> show master status;
+------------------+----------+----------------+------------------+-------------------+
| File | Position | Binlog_Do_DB | Binlog_Ignore_DB | Executed_Gtid_Set |
+------------------+----------+----------------+------------------+-------------------+
| mysql-bin.000198 | 56961637 | cctns_state_db | | |
+------------------+----------+----------------+------------------+-------------------+
1 row in set (0.00 sec)

mysql> use cctns_state_db;
Database changed
mysql> show master status;
+------------------+----------+----------------+------------------+-------------------+
| File | Position | Binlog_Do_DB | Binlog_Ignore_DB | Executed_Gtid_Set |
+------------------+----------+----------------+------------------+-------------------+
| mysql-bin.000198 | 56965741 | cctns_state_db | | |
+------------------+----------+----------------+------------------+-------------------+
1 row in set (0.00 sec)

Options: ReplyQuote


Subject
Views
Written By
Posted
Show master status log position
9951
June 30, 2015 12:19AM
1502
July 03, 2015 09:06PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.