109 lines
7.3 KiB
Plaintext
109 lines
7.3 KiB
Plaintext
include/master-slave.inc
|
|
Warnings:
|
|
Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
|
|
Note #### 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.
|
|
[connection master]
|
|
call mtr.add_suppression("Slave I/O for channel '': Got a packet bigger than 'slave_max_allowed_packet' bytes, Error_code: 1153");
|
|
call mtr.add_suppression("Log entry on master is longer than slave_max_allowed_packet");
|
|
drop database if exists DB_NAME_OF_MAX_LENGTH_AKA_NAME_LEN_64_BYTES_____________________;
|
|
create database DB_NAME_OF_MAX_LENGTH_AKA_NAME_LEN_64_BYTES_____________________;
|
|
SET @@global.max_allowed_packet=10240;
|
|
SET @@global.net_buffer_length=1024;
|
|
include/sync_slave_sql_with_master.inc
|
|
include/stop_slave.inc
|
|
include/start_slave.inc
|
|
select @@net_buffer_length, @@max_allowed_packet;
|
|
@@net_buffer_length @@max_allowed_packet
|
|
1024 10240
|
|
create table `t1` (`f1` LONGTEXT);
|
|
INSERT INTO `t1`(`f1`) VALUES ('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa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aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa2048');
|
|
include/sync_slave_sql_with_master.inc
|
|
select count(*) from `DB_NAME_OF_MAX_LENGTH_AKA_NAME_LEN_64_BYTES_____________________`.`t1` /* must be 1 */;
|
|
count(*)
|
|
1
|
|
SHOW STATUS LIKE 'Slave_running';
|
|
Variable_name Value
|
|
Slave_running ON
|
|
select * from information_schema.session_status where variable_name= 'SLAVE_RUNNING';
|
|
VARIABLE_NAME VARIABLE_VALUE
|
|
SLAVE_RUNNING ON
|
|
drop database DB_NAME_OF_MAX_LENGTH_AKA_NAME_LEN_64_BYTES_____________________;
|
|
include/sync_slave_sql_with_master.inc
|
|
SET @@global.max_allowed_packet=4096 + (floor(64 * 3 * 254 / 1024) + 1) * 1024;
|
|
SET @@global.net_buffer_length=@@global.max_allowed_packet;
|
|
include/stop_slave.inc
|
|
include/start_slave.inc
|
|
CREATE TABLE `t1` (`f1` LONGTEXT);
|
|
include/sync_slave_sql_with_master.inc
|
|
INSERT INTO t1 VALUES (REPEAT('a', @@global.max_allowed_packet));
|
|
include/wait_for_slave_io_error.inc [errno=1153]
|
|
Warnings:
|
|
Warning 3090 Changing sql mode 'NO_AUTO_CREATE_USER' is deprecated. It will be removed in a future release.
|
|
Last_IO_Error = 'Got a packet bigger than 'slave_max_allowed_packet' bytes'
|
|
Warnings:
|
|
Warning 3090 Changing sql mode 'NO_AUTO_CREATE_USER' is deprecated. It will be removed in a future release.
|
|
include/stop_slave_sql.inc
|
|
include/rpl_reset.inc
|
|
DROP TABLE t1;
|
|
include/sync_slave_sql_with_master.inc
|
|
CREATE TABLE t1 (f1 int PRIMARY KEY, f2 LONGTEXT, f3 LONGTEXT) ENGINE=MyISAM;
|
|
include/sync_slave_sql_with_master.inc
|
|
INSERT INTO t1(f1, f2, f3) VALUES(1, REPEAT('a', @@global.max_allowed_packet), REPEAT('b', @@global.max_allowed_packet));
|
|
include/wait_for_slave_io_error.inc [errno=1153]
|
|
Warnings:
|
|
Warning 3090 Changing sql mode 'NO_AUTO_CREATE_USER' is deprecated. It will be removed in a future release.
|
|
Last_IO_Error = 'Got a packet bigger than 'slave_max_allowed_packet' bytes'
|
|
Warnings:
|
|
Warning 3090 Changing sql mode 'NO_AUTO_CREATE_USER' is deprecated. It will be removed in a future release.
|
|
STOP SLAVE;
|
|
RESET SLAVE;
|
|
RESET MASTER;
|
|
RESET MASTER;
|
|
SET @max_allowed_packet_0= @@session.max_allowed_packet;
|
|
SHOW BINLOG EVENTS;
|
|
SET @max_allowed_packet_1= @@session.max_allowed_packet;
|
|
SHOW BINLOG EVENTS;
|
|
SET @max_allowed_packet_2= @@session.max_allowed_packet;
|
|
START SLAVE;
|
|
include/wait_for_slave_to_start.inc
|
|
DROP TABLE t1;
|
|
select @@global.max_allowed_packet;
|
|
@@global.max_allowed_packet
|
|
53248
|
|
select @@global.net_buffer_length;
|
|
@@global.net_buffer_length
|
|
53248
|
|
include/sync_slave_sql_with_master.inc
|
|
select @@global.max_allowed_packet;
|
|
@@global.max_allowed_packet
|
|
2048
|
|
select @@global.net_buffer_length;
|
|
@@global.net_buffer_length
|
|
1024
|
|
CREATE TABLE t1 (a TEXT) ENGINE=MyISAM;
|
|
include/sync_slave_sql_with_master.inc
|
|
INSERT INTO t1 VALUES (REPEAT('a', @@global.max_allowed_packet));
|
|
# 1153 = ER_NET_PACKET_TOO_LARGE
|
|
include/wait_for_slave_io_error.inc [errno=1153]
|
|
Warnings:
|
|
Warning 3090 Changing sql mode 'NO_AUTO_CREATE_USER' is deprecated. It will be removed in a future release.
|
|
Last_IO_Error = 'Got a packet bigger than 'slave_max_allowed_packet' bytes'
|
|
Warnings:
|
|
Warning 3090 Changing sql mode 'NO_AUTO_CREATE_USER' is deprecated. It will be removed in a future release.
|
|
# Record Read_Master_Log_Pos for the Table_map_log_event
|
|
SET @@global.max_allowed_packet=1048576;
|
|
WARNING: The range of printed events ends with a row event or a table map event that does not have the STMT_END_F flag set. This might be because the last statement was not fully written to the log, or because you are using a --stop-position or --stop-datetime that refers to an event in the middle of a statement. The event(s) from the partial statement have not been written to output.
|
|
WARNING: The range of printed events ends with a row event or a table map event that does not have the STMT_END_F flag set. This might be because the last statement was not fully written to the log, or because you are using a --stop-position or --stop-datetime that refers to an event in the middle of a statement. The event(s) from the partial statement have not been written to output.
|
|
==== clean up ====
|
|
DROP TABLE t1;
|
|
SET @@global.max_allowed_packet= 4096;
|
|
Warnings:
|
|
Warning 1708 The value of 'max_allowed_packet' should be no less than the value of 'net_buffer_length'
|
|
SET @@global.net_buffer_length= 1024;
|
|
SET @@global.slave_max_allowed_packet= 4096;
|
|
SET @@global.max_allowed_packet= 2048;
|
|
DROP TABLE t1;
|
|
include/stop_slave_sql.inc
|
|
RESET SLAVE;
|
|
include/rpl_end.inc
|