-- Simulate the net blocking as reported suggested cat bug97955.patch --- mysql-8.0.18/sql/rpl_master.cc 2019-09-20 10:30:51.000000000 +0200 +++ mysql-8.0.18a/sql/rpl_master.cc 2019-12-11 08:05:46.295073339 +0100 @@ -1339,6 +1339,7 @@ } protocol->store(file_length); protocol->store(encrypted_header_size ? "Yes" : "No", &my_charset_bin); + DBUG_EXECUTE_IF("simulate_network_blocking", sleep(50);); if (protocol->end_row()) { DBUG_PRINT( "info", export LD_LIBRARY_PATH=/export/umesh/utils/GCC-7.3.0/lib64 export CC=/export/umesh/utils/GCC-7.3.0/bin/gcc export CPP=/export/umesh/utils/GCC-7.3.0/bin/cpp export CXX=/export/umesh/utils/GCC-7.3.0/bin/c++ rm -rf bld/ mkdir bld && cd bld rm -rf CMakeCache.txt /export/umesh/utils/cmake-3.14.4/bin/cmake .. \ -DCMAKE_BUILD_TYPE=Debug \ -DBUILD_CONFIG=mysql_release \ -DINSTALL_LAYOUT=STANDALONE \ -DWITH_NDBCLUSTER_STORAGE_ENGINE=0 \ -DCMAKE_INSTALL_PREFIX=$PWD \ -DWITH_BOOST=../boost \ -DWITH_UNIT_TESTS=0 make -j32 make install cp ./runtime_output_directory/mysqld-debug ./runtime_output_directory/mysqld rm -rf 97955/ bin/mysqld --initialize-insecure --basedir=$PWD --datadir=$PWD/97955 --log-error-verbosity=3 bin/mysqld --no-defaults --basedir=$PWD --datadir=$PWD/97955 --core-file --socket=/tmp/mysql_ushastry.sock --port=3333 --log-error=$PWD/97955/log.err --mysqlx-port=33330 --mysqlx-socket=/tmp/mysql_x_ushastry.sock --log-error-verbosity=3 --secure-file-priv=/tmp/ 2>&1 & - Session 1 bin/mysql -uroot -S /tmp/mysql_ushastry.sock Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 7 Server version: 8.0.18-debug Source distribution Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> create database if not exists test; Query OK, 1 row affected, 1 warning (0.00 sec) mysql> use test; Database changed mysql> DROP TABLE IF EXISTS example_table; Query OK, 0 rows affected, 1 warning (0.01 sec) mysql> CREATE TABLE example_table ( -> id varchar(100) NULL -> ); Query OK, 0 rows affected (0.03 sec) mysql> INSERT INTO example_table (id) VALUES (1),(2),(3),(4),(5),(6),(7),(8); Query OK, 8 rows affected (0.02 sec) Records: 8 Duplicates: 0 Warnings: 0 mysql> - Session 2 bin/mysql -uroot -S /tmp/mysql_ushastry.sock --prompt='Session2>' Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 8 Server version: 8.0.18-debug Source distribution Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. Session2>use test Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database changed Session2> - Session 3 bin/mysql -uroot -S /tmp/mysql_ushastry.sock --prompt='Session3>' Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 9 Server version: 8.0.18-debug Source distribution Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. Session3>use test Database changed Session3>use test Database changed Session3> -- Session 1 mysql> SET @@GLOBAL.DEBUG= '+d,simulate_network_blocking'; Query OK, 0 rows affected (0.00 sec) mysql> show binary logs; +---------------+-----------+-----------+ | Log_name | File_size | Encrypted | +---------------+-----------+-----------+ | binlog.000001 | 1277 | No | +---------------+-----------+-----------+ 1 row in set (50.00 sec) -- Session 2 Session2>show binary logs; +---------------+-----------+-----------+ | Log_name | File_size | Encrypted | +---------------+-----------+-----------+ | binlog.000001 | 1277 | No | +---------------+-----------+-----------+ 1 row in set (1 min 38.27 sec) -- Session 3 Session3>insert into example_table values(10); Query OK, 1 row affected (66.92 sec) Session3>