0
我的主人的位置不更新,我已经经历了所有其他复制问题帖子,我可以找到......仍然没有运气。下面是我有:MySQL复制 - 主位置不变
大师的/etc/my.cnf
[mysqld]
server-id = 1
log-bin = /var/log/mysql/binary.log
binlog_do_db = securityDB
从/etc/my.cnf中
[mysqld]
server-id = 2
master-host = 192.168.1.130
master-port = 3306
master-user = slave
master-password = slave
replicate-do-db = securityDB
在主ProcessList中显示,从连接:
*************************** 4. row ***************************
Id: 86
User: root
Host: localhost:59948
db: securitydb
Command: Sleep
Time: 350
State:
Info: NULL
*************************** 5. row ***************************
Id: 138
User: root
Host: localhost
db: securitydb
Command: Query
Time: 0
State: NULL
Info: show processlist
*************************** 6. row ***************************
Id: 187
User: slave
Host: macbookpro17:59477
db: NULL
Command: Binlog Dump
Time: 600
State: Master has sent all binlog to slave; waiting for binlog to be updated
Info: NULL
The slave process list shows that it's connected to the master:
*************************** 5. row ***************************
Id: 532
User: root
Host: localhost
db: securitydb
Command: Sleep
Time: 689
State:
Info: NULL
*************************** 6. row ***************************
Id: 922
User: system user
Host:
db: NULL
Command: Connect
Time: 715
State: Waiting for master to send event
Info: NULL
*************************** 7. row ***************************
Id: 923
User: system user
Host:
db: NULL
Command: Connect
Time: 714
State: Slave has read all relay log; waiting for the slave I/O thread to update it
Info: NULL
主变量,如 '1/4区段%':
+-----------------------------------------+----------------------+
| Variable_name | Value |
+-----------------------------------------+----------------------+
| binlog_cache_size | 32768 |
| binlog_direct_non_transactional_updates | OFF |
| binlog_format | STATEMENT |
| binlog_stmt_cache_size | 32768 |
| innodb_locks_unsafe_for_binlog | OFF |
| log_bin | ON |
| log_bin_trust_function_creators | OFF |
| max_binlog_cache_size | 18446744073709547520 |
| max_binlog_size | 1073741824 |
| max_binlog_stmt_cache_size | 18446744073709547520 |
| sql_log_bin | ON |
| sync_binlog | 0 |
+-----------------------------------------+----------------------+
从属变量,如 '1/4区段%':
+-----------------------------------------+--------------------------------+
| Variable_name | Value |
+-----------------------------------------+--------------------------------+
| bind_address | * |
| binlog_cache_size | 32768 |
| binlog_checksum | CRC32 |
| binlog_direct_non_transactional_updates | OFF |
| binlog_format | STATEMENT |
| binlog_max_flush_queue_time | 0 |
| binlog_order_commits | ON |
| binlog_row_image | FULL |
| binlog_rows_query_log_events | OFF |
| binlog_stmt_cache_size | 32768 |
| innodb_api_enable_binlog | OFF |
| innodb_locks_unsafe_for_binlog | OFF |
| log_bin | ON |
| log_bin_basename | /var/lib/mysql/mysql-bin |
| log_bin_index | /var/lib/mysql/mysql-bin.index |
| log_bin_trust_function_creators | OFF |
| log_bin_use_v1_row_events | OFF |
| max_binlog_cache_size | 18446744073709547520 |
| max_binlog_size | 1073741824 |
| max_binlog_stmt_cache_size | 18446744073709547520 |
| sql_log_bin | ON |
| sync_binlog | 0 |
+-----------------------------------------+--------------------------------+
但主位置没有移动和replcation被卡住。我注意到数据库在进程列表中显示为所有小写字母,但我已将replicate_do_db更改为全部小写,并且没有帮助。数据库名称实际上是securityDB。我已经尝试了主复位,从复位,创建新的bin日志......没有什么让我在那里。我敢肯定,这是简单的...
任何意见将不胜感激。
不是一个问题为[所以]。 [dba.se]会是个更好的地方。 – 2013-10-26 02:13:08
创建一个复制用户帐户并给予适当的权利。 – Trying
事实证明,数据库名称在启动时已转换为小写字母,因此需要使用小写来配置复制。 – user2234592