include/master-slave.inc [connection master] drop table if exists test.t1; reset master; create table test.t1(a int); drop table test.t1; show binlog events from <binlog_start>; Log_name Pos Event_type Server_id End_log_pos Info slave-bin.000001 # Query # # use `test`; create table test.t1(a int) slave-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */ "============ Performance schema on master ============" select * from performance_schema.file_summary_by_instance where file_name like "%master-%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE [DATADIR]master-bin.000001 wait/io/file/sql/binlog 6 4 221 329 [DATADIR]master-bin.index wait/io/file/sql/binlog_index 0 2 0 40 select * from performance_schema.file_summary_by_instance where file_name like "%slave-%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE select * from performance_schema.file_summary_by_instance where event_name like "%binlog%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE [DATADIR]master-bin.000001 wait/io/file/sql/binlog 6 4 221 329 [DATADIR]master-bin.index wait/io/file/sql/binlog_index 0 2 0 40 select * from performance_schema.file_summary_by_event_name where event_name like "%binlog%" order by event_name; EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE wait/io/file/sql/binlog 6 4 221 329 wait/io/file/sql/binlog_index 0 2 0 40 select event_name, count_star from performance_schema.events_waits_summary_global_by_event_name where event_name like "%MYSQL_BIN_LOG%" order by event_name; event_name count_star wait/synch/cond/sql/MYSQL_BIN_LOG::COND_prep_xids 0 wait/synch/cond/sql/MYSQL_BIN_LOG::update_cond 1 wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_index 3 wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_prep_xids 0 select * from performance_schema.file_summary_by_instance where event_name like "%relaylog%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE select * from performance_schema.file_summary_by_event_name where event_name like "%relaylog%" order by event_name; EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE wait/io/file/sql/relaylog 0 0 0 0 wait/io/file/sql/relaylog_index 0 0 0 0 select * from performance_schema.events_waits_summary_global_by_event_name where event_name like "%MYSQL_RELAY_LOG%" order by event_name; EVENT_NAME COUNT_STAR SUM_TIMER_WAIT MIN_TIMER_WAIT AVG_TIMER_WAIT MAX_TIMER_WAIT wait/synch/cond/sql/MYSQL_RELAY_LOG::update_cond 0 0 0 0 0 wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_index 0 0 0 0 0 "============ Performance schema on slave ============" select * from performance_schema.file_summary_by_instance where file_name like "%master-%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE select * from performance_schema.file_summary_by_instance where file_name like "%slave-%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE [DATADIR]slave-bin.000001 wait/io/file/sql/binlog 3 8 602 631 [DATADIR]slave-bin.index wait/io/file/sql/binlog_index 0 3 0 57 [DATADIR]slave-relay-bin.000001 wait/io/file/sql/relaylog 4 3 370 263 [DATADIR]slave-relay-bin.000002 wait/io/file/sql/relaylog 2 4 368 368 [DATADIR]slave-relay-bin.index wait/io/file/sql/relaylog_index 2 4 50 125 select * from performance_schema.file_summary_by_instance where event_name like "%binlog%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE [DATADIR]slave-bin.000001 wait/io/file/sql/binlog 3 8 602 631 [DATADIR]slave-bin.index wait/io/file/sql/binlog_index 0 3 0 57 select * from performance_schema.file_summary_by_event_name where event_name like "%binlog%" order by event_name; EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE wait/io/file/sql/binlog 3 8 602 631 wait/io/file/sql/binlog_index 0 3 0 57 select event_name, count_star from performance_schema.events_waits_summary_global_by_event_name where event_name like "%MYSQL_BIN_LOG%" order by event_name; event_name count_star wait/synch/cond/sql/MYSQL_BIN_LOG::COND_prep_xids 0 wait/synch/cond/sql/MYSQL_BIN_LOG::update_cond 0 wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_index 5 wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_prep_xids 0 select * from performance_schema.file_summary_by_instance where event_name like "%relaylog%" order by file_name; FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE [DATADIR]slave-relay-bin.000001 wait/io/file/sql/relaylog 4 3 370 263 [DATADIR]slave-relay-bin.000002 wait/io/file/sql/relaylog 2 4 368 368 [DATADIR]slave-relay-bin.index wait/io/file/sql/relaylog_index 2 4 50 125 select * from performance_schema.file_summary_by_event_name where event_name like "%relaylog%" order by event_name; EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE wait/io/file/sql/relaylog 6 7 738 631 wait/io/file/sql/relaylog_index 2 4 50 125 select event_name, count_star from performance_schema.events_waits_summary_global_by_event_name where event_name like "%MYSQL_RELAY_LOG%" order by event_name; event_name count_star wait/synch/cond/sql/MYSQL_RELAY_LOG::update_cond 2 wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_index 12 include/stop_slave.inc