// How to repeat -- conf files [umshastr@hod03]/export/umesh/server/binaries/mysql-5.6.26: cat master_78352.cnf #Master [mysqld] pid-file = /export/umesh/server/binaries/mysql-5.6.26/run/master.pid socket = /export/umesh/server/binaries/mysql-5.6.26/run/master.sock log-error=/export/umesh/server/binaries/mysql-5.6.26/log/master.log slow_query_log_file=/export/umesh/server/binaries/mysql-5.6.26/log/slow.log general_log_file=/export/umesh/server/binaries/mysql-5.6.26/log/general.log port = 15000 server-id = 1 basedir = /export/umesh/server/binaries/mysql-5.6.26 datadir = /export/umesh/server/binaries/mysql-5.6.26/master tmpdir = /tmp log-bin = /export/umesh/server/binaries/mysql-5.6.26/log/master-bin log-bin-index = /export/umesh/server/binaries/mysql-5.6.26/log/master-bin.index binlog_format=ROW [umshastr@hod03]/export/umesh/server/binaries/mysql-5.7.8-rc: cat slave_78352.cnf #Slave [mysqld] pid-file = /export/umesh/server/binaries/mysql-5.7.8-rc/run/slave.pid socket = /export/umesh/server/binaries/mysql-5.7.8-rc/run/slave.sock log-error=/export/umesh/server/binaries/mysql-5.7.8-rc/log/slave.log port = 15001 server-id = 2 basedir = /export/umesh/server/binaries/mysql-5.7.8-rc datadir = /export/umesh/server/binaries/mysql-5.7.8-rc/slave tmpdir = /tmp relay-log-index = /export/umesh/server/binaries/mysql-5.7.8-rc/log/slave-relay-bin.index relay-log = /export/umesh/server/binaries/mysql-5.7.8-rc/log/slave-relay-bin binlog_format=ROW log_slow_slave_statements=ON slow_query_log=ON long_query_time=0 master_info_repository = TABLE relay_log_info_repository = TABLE relay_log_recovery = ON master_verify_checksum = ON -- Startup commands used scripts/mysql_install_db --basedir=/export/umesh/server/binaries/mysql-5.6.26 --datadir=/export/umesh/server/binaries/mysql-5.6.26/master bin/mysqld --defaults-file=./master_78352.cnf 2>&1 & bin/mysql_install_db --insecure --basedir=/export/umesh/server/binaries/mysql-5.7.8-rc --datadir=/export/umesh/server/binaries/mysql-5.7.8-rc/slave -v bin/mysqld --defaults-file=./slave_78352.cnf 2>&1 & -- Schema used for tests use test; create table t1 ( id int primary key, value int, value2 varchar(255) )engine=innodb; ## Dump file for loading #!/bin/perl for(my $i=1; $i <= 50000000; $i++) { my $txt = 'x' x 250; print "$i,$i,$txt\n"; } [umshastr@hod03]/export/umesh/server/binaries/mysql-5.6.26: vi bug78352.pl [umshastr@hod03]/export/umesh/server/binaries/mysql-5.6.26: chmod 755 bug78352.pl [umshastr@hod03]/export/umesh/server/binaries/mysql-5.6.26: perl bug78352.pl >> dump.sql [umshastr@hod03]/export/umesh/server/binaries/mysql-5.6.26: ls -lh dump.sql -rw-r--r-- 1 umshastr common 13G Sep 7 13:48 dump.sql [umshastr@hod03]/export/umesh/server/binaries/mysql-5.6.26: // Setup replication(master with 5.6.26, and slave with 5.7.8) - Stop sql thread mysql> STOP SLAVE SQL_THREAD; Query OK, 0 rows affected (0.01 sec) mysql> show slave status\G *************************** 1. row *************************** Slave_IO_State: Waiting for master to send event Master_Host: localhost Master_User: repl Master_Port: 15000 Connect_Retry: 60 Master_Log_File: master-bin.000001 Read_Master_Log_Pos: 813 Relay_Log_File: slave-relay-bin.000002 Relay_Log_Pos: 318 Relay_Master_Log_File: master-bin.000001 Slave_IO_Running: Yes Slave_SQL_Running: No - on master mysql> use test; Database changed mysql> create table t1 ( -> id int primary key, -> value int, -> value2 varchar(255) -> )engine=innodb; Query OK, 0 rows affected (0.00 sec) mysql> load data local infile 'dump.sql' into table t1 fields terminated by ','; Query OK, 50000000 rows affected (8 min 24.22 sec) Records: 50000000 Deleted: 0 Skipped: 0 Warnings: 0 mysql> - Confirm relaylog size on slave mysql> \! ls -lh log/slave-relay-bin.[0-9]* -rw-r----- 1 umshastr common 207 Sep 7 13:45 log/slave-relay-bin.000001 -rw-r----- 1 umshastr common 13G Sep 7 14:01 log/slave-relay-bin.000002 -rw-r----- 1 umshastr common 255 Sep 7 14:01 log/slave-relay-bin.000003 -rw-r----- 1 umshastr common 318 Sep 7 14:01 log/slave-relay-bin.000004 mysql> -- restart slave, check error log (~63 sec for 13G relay log) 2015-09-07T12:04:09.541853Z 0 [Note] InnoDB: 5.7.8 started; log sequence number 2546151 2015-09-07T12:04:09.541976Z 0 [Note] InnoDB: Loading buffer pool(s) from .//ib_buffer_pool 2015-09-07T12:04:09.542240Z 0 [Note] Plugin 'FEDERATED' is disabled. 2015-09-07T12:04:09.542459Z 0 [Note] InnoDB: Buffer pool(s) load completed at 150907 14:04:09 2015-09-07T12:04:09.543964Z 0 [Warning] Failed to setup SSL 2015-09-07T12:04:09.543990Z 0 [Warning] SSL error: SSL context is not usable without certificate and private key 2015-09-07T12:04:09.543999Z 0 [Note] Server hostname (bind-address): '*'; port: 15001 2015-09-07T12:04:09.544065Z 0 [Note] IPv6 is available. 2015-09-07T12:04:09.544078Z 0 [Note] - '::' resolves to '::'; 2015-09-07T12:04:09.544084Z 0 [Note] Server socket created on IP: '::'. 2015-09-07T12:05:12.418733Z 0 [Warning] Recovery from master pos 813 and file master-bin.000001 for channel ''. Previous relay log pos and relay log file had been set to 318, /export/umesh/server/binaries/mysql-5.7.8-rc/log/slave-relay-bin.000002 respectively. 2015-09-07T12:05:12.419635Z 2 [Warning] Storing MySQL user name or password information in the master info repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START SLAVE; see the 'START SLAVE Syntax' in the MySQL Manual for more information. 2015-09-07T12:05:12.419907Z 1 [Note] Slave SQL thread for channel '' initialized, starting replication in log 'master-bin.000001' at position 813, relay log '/export/umesh/server/binaries/mysql-5.7.8-rc/log/slave-relay-bin.000005' position: 4 2015-09-07T12:05:12.420459Z 2 [Note] Slave I/O thread for channel '': connected to master 'repl@localhost:15000',replication started in log 'master-bin.000001' at position 813 2015-09-07T12:05:12.425900Z 0 [Note] Event Scheduler: Loaded 0 events 2015-09-07T12:05:12.426048Z 0 [Note] bin/mysqld: ready for connections. Version: '5.7.8-rc-log' socket: '/export/umesh/server/binaries/mysql-5.7.8-rc/run/slave.sock' port: 15001 MySQL Community Server (GPL) ##### Setup replication(master and slave with 5.6.26), repeat steps in previous case -- Startup commands used scripts/mysql_install_db --basedir=/export/umesh/server/binaries/mysql-5.6.26 --datadir=/export/umesh/server/binaries/mysql-5.6.26/master bin/mysqld --defaults-file=./master_78352.cnf 2>&1 & scripts/mysql_install_db --basedir=/export/umesh/server/binaries/mysql-5.6.26 --datadir=/export/umesh/server/binaries/mysql-5.6.26/slave bin/mysqld --defaults-file=./slave_78352.cnf 2>&1 & - Stop sql thread mysql> STOP SLAVE SQL_THREAD; Query OK, 0 rows affected (0.00 sec) mysql> show slave status\G *************************** 1. row *************************** Slave_IO_State: Waiting for master to send event Master_Host: localhost Master_User: repl Master_Port: 15000 Connect_Retry: 60 Master_Log_File: master-bin.000001 Read_Master_Log_Pos: 813 Relay_Log_File: slave-relay-bin.000002 Relay_Log_Pos: 284 Relay_Master_Log_File: master-bin.000001 Slave_IO_Running: Yes Slave_SQL_Running: No Replicate_Do_DB: - on master mysql> use test; Database changed mysql> create table t1 ( -> id int primary key, -> value int, -> value2 varchar(255) -> )engine=innodb; Query OK, 0 rows affected (0.00 sec) mysql> load data local infile 'dump.sql' into table t1 fields terminated by ','; Query OK, 50000000 rows affected (8 min 31.34 sec) Records: 50000000 Deleted: 0 Skipped: 0 Warnings: 0 - Confirm relaylog size on slave mysql> \! ls -lh log/slave-relay-bin.[0-9]* -rw-rw---- 1 umshastr common 173 Sep 7 14:20 log/slave-relay-bin.000001 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:30 log/slave-relay-bin.000002 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:30 log/slave-relay-bin.000003 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:30 log/slave-relay-bin.000004 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000005 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000006 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000007 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000008 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000009 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000010 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000011 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000012 -rw-rw---- 1 umshastr common 1.1G Sep 7 14:31 log/slave-relay-bin.000013 -rw-rw---- 1 umshastr common 164M Sep 7 14:31 log/slave-relay-bin.000014 -rw-rw---- 1 umshastr common 221 Sep 7 14:31 log/slave-relay-bin.000015 -rw-rw---- 1 umshastr common 284 Sep 7 14:31 log/slave-relay-bin.000016 mysql> -- restart slave, check error log (~63 sec for 13G relay log) 2015-09-07 14:32:47 13334 [Note] InnoDB: Using atomics to ref count buffer pool pages 2015-09-07 14:32:47 13334 [Note] InnoDB: The InnoDB memory heap is disabled 2015-09-07 14:32:47 13334 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins 2015-09-07 14:32:47 13334 [Note] InnoDB: Memory barrier is not used 2015-09-07 14:32:47 13334 [Note] InnoDB: Compressed tables use zlib 1.2.3 2015-09-07 14:32:47 13334 [Note] InnoDB: Using Linux native AIO 2015-09-07 14:32:47 13334 [Note] InnoDB: Using CPU crc32 instructions 2015-09-07 14:32:47 13334 [Note] InnoDB: Initializing buffer pool, size = 128.0M 2015-09-07 14:32:47 13334 [Note] InnoDB: Completed initialization of buffer pool 2015-09-07 14:32:47 13334 [Note] InnoDB: Highest supported file format is Barracuda. 2015-09-07 14:32:47 13334 [Note] InnoDB: 128 rollback segment(s) are active. 2015-09-07 14:32:47 13334 [Note] InnoDB: Waiting for purge to start 2015-09-07 14:32:47 13334 [Note] InnoDB: 5.6.26 started; log sequence number 1782737 2015-09-07 14:32:47 13334 [Note] Server hostname (bind-address): '*'; port: 15001 2015-09-07 14:32:47 13334 [Note] IPv6 is available. 2015-09-07 14:32:47 13334 [Note] - '::' resolves to '::'; 2015-09-07 14:32:47 13334 [Note] Server socket created on IP: '::'. 2015-09-07 14:32:47 13334 [Warning] Recovery from master pos 813 and file master-bin.000001. 2015-09-07 14:32:47 13334 [Warning] Storing MySQL user name or password information in the master info repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START SLAVE; see the 'START SLAVE Syntax' in the MySQL Manual for more information. 2015-09-07 14:32:47 13334 [Note] Slave SQL thread initialized, starting replication in log 'master-bin.000001' at position 813, relay log '/export/umesh/server/binaries/mysql-5.6.26/log/slave-relay-bin.000017' position: 4 2015-09-07 14:32:47 13334 [Note] Slave I/O thread: connected to master 'repl@localhost:15000',replication started in log 'master-bin.000001' at position 813 2015-09-07 14:32:47 13334 [Note] Event Scheduler: Loaded 0 events 2015-09-07 14:32:47 13334 [Note] bin/mysqld: ready for connections. Version: '5.6.26-log' socket: '/export/umesh/server/binaries/mysql-5.6.26/run/slave.sock' port: 15001 MySQL Community Server (GPL)