summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2014-05-07 10:04:30 +0200
committerSergei Golubchik <sergii@pisem.net>2014-05-07 10:04:30 +0200
commit04bce7b569f44f3aca3cb21953d41c2a4a02efe6 (patch)
tree2530ccd90b42afa39b0a60f4454fd5ddb97c95e1 /mysql-test
parent7226287c066228a216217c43c48f3a0a833d9909 (diff)
downloadmariadb-git-04bce7b569f44f3aca3cb21953d41c2a4a02efe6.tar.gz
5.6.17
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/suite/perfschema/include/disable_instruments.inc23
-rw-r--r--mysql-test/suite/perfschema/include/enable_instruments.inc23
-rw-r--r--mysql-test/suite/perfschema/include/event_aggregate_setup.inc4
-rw-r--r--mysql-test/suite/perfschema/include/rpl_statements_truncate.inc15
-rw-r--r--mysql-test/suite/perfschema/include/sizing_auto.inc4
-rw-r--r--mysql-test/suite/perfschema/r/binlog_edge_row.result4
-rw-r--r--mysql-test/suite/perfschema/r/dml_setup_instruments.result6
-rw-r--r--mysql-test/suite/perfschema/r/func_file_io.result1
-rw-r--r--mysql-test/suite/perfschema/r/func_mutex.result1
-rw-r--r--mysql-test/suite/perfschema/r/hostcache_ipv4_blocked.result220
-rw-r--r--mysql-test/suite/perfschema/r/hostcache_ipv6_blocked.result220
-rw-r--r--mysql-test/suite/perfschema/r/innodb_table_io.result3
-rw-r--r--mysql-test/suite/perfschema/r/myisam_file_io.result1
-rw-r--r--mysql-test/suite/perfschema/r/ortho_iter.result42
-rw-r--r--mysql-test/suite/perfschema/r/pfs_upgrade_event.result106
-rw-r--r--mysql-test/suite/perfschema/r/pfs_upgrade_func.result106
-rw-r--r--mysql-test/suite/perfschema/r/pfs_upgrade_proc.result106
-rw-r--r--mysql-test/suite/perfschema/r/pfs_upgrade_table.result106
-rw-r--r--mysql-test/suite/perfschema/r/pfs_upgrade_view.result106
-rw-r--r--mysql-test/suite/perfschema/r/privilege_table_io.result4
-rw-r--r--mysql-test/suite/perfschema/r/relaylog.result8
-rw-r--r--mysql-test/suite/perfschema/r/rpl_gtid_func.result2
-rw-r--r--mysql-test/suite/perfschema/r/rpl_statements.result244
-rw-r--r--mysql-test/suite/perfschema/r/setup_instruments_defaults.result40
-rw-r--r--mysql-test/suite/perfschema/r/sizing_default.result208
-rw-r--r--mysql-test/suite/perfschema/r/sizing_high.result60
-rw-r--r--mysql-test/suite/perfschema/r/sizing_low.result60
-rw-r--r--mysql-test/suite/perfschema/r/sizing_med.result60
-rw-r--r--mysql-test/suite/perfschema/r/sizing_off.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_disable_idle.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_disable_stages.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_disable_statements.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_disable_waits.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_innodb.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_account.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_cond_class.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_cond_inst.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_file_class.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_file_inst.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_host.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_mutex_class.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_mutex_inst.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_rwlock_class.result2
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_rwlock_inst.result6
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_setup_actors.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_setup_objects.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_socket_class.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_socket_inst.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_stage_class.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_stages_history.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_stages_history_long.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_statement_class.result2
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_statements_history.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_statements_history_long.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_table_hdl.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_table_inst.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_thread_class.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_thread_inst.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_user.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_waits_history.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_no_waits_history_long.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_off.result4
-rw-r--r--mysql-test/suite/perfschema/r/start_server_on.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_global_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_global_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_global_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_global_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_hist_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_hist_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_hist_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_hist_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_off.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_thread_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_thread_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_thread_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_aggregate_thread_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_2t.result4
-rw-r--r--mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_3t.result4
-rw-r--r--mysql-test/suite/perfschema/t/aggregate.test1
-rw-r--r--mysql-test/suite/perfschema/t/disabled.def3
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate.test2
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate_no_a.test2
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate_no_a_no_h.test2
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u.test2
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u_no_h.test2
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate_no_h.test2
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate_no_u.test2
-rw-r--r--mysql-test/suite/perfschema/t/event_aggregate_no_u_no_h.test2
-rw-r--r--mysql-test/suite/perfschema/t/func_file_io.test1
-rw-r--r--mysql-test/suite/perfschema/t/func_mutex.test1
-rw-r--r--mysql-test/suite/perfschema/t/hostcache_ipv4_blocked.test81
-rw-r--r--mysql-test/suite/perfschema/t/hostcache_ipv6_blocked.test81
-rw-r--r--mysql-test/suite/perfschema/t/myisam_file_io.test1
-rw-r--r--mysql-test/suite/perfschema/t/nesting.test6
-rw-r--r--mysql-test/suite/perfschema/t/ortho_iter.test4
-rw-r--r--mysql-test/suite/perfschema/t/rpl_statements-master.opt1
-rw-r--r--mysql-test/suite/perfschema/t/rpl_statements-slave.opt1
-rw-r--r--mysql-test/suite/perfschema/t/rpl_statements.test338
-rw-r--r--mysql-test/suite/perfschema/t/setup_instruments_defaults-master.opt29
-rw-r--r--mysql-test/suite/perfschema/t/setup_instruments_defaults.test61
-rw-r--r--mysql-test/suite/perfschema/t/sizing_default.cnf11
-rw-r--r--mysql-test/suite/perfschema/t/sizing_default.test22
-rw-r--r--mysql-test/suite/perfschema/t/view_table_io.test1
125 files changed, 2043 insertions, 685 deletions
diff --git a/mysql-test/suite/perfschema/include/disable_instruments.inc b/mysql-test/suite/perfschema/include/disable_instruments.inc
new file mode 100644
index 00000000000..b0a4ddec450
--- /dev/null
+++ b/mysql-test/suite/perfschema/include/disable_instruments.inc
@@ -0,0 +1,23 @@
+# Tests for the performance schema
+
+# ==========================================
+# HELPER include/disable_instruments
+# ==========================================
+#
+# ==== Usage ====
+#
+# 1. Define the instrument to be disabled/enabled:
+#
+# let $pfs_instrument=<instrument>
+#
+# Where <instrument> is the instrument name with or without wildcards, e.g.
+#
+# let $pfs_instrument='%statement/sql%'
+#
+--disable_query_log ONCE
+
+eval update performance_schema.setup_instruments
+ set enabled='no', timed='no'
+ where name like $pfs_instrument;
+
+
diff --git a/mysql-test/suite/perfschema/include/enable_instruments.inc b/mysql-test/suite/perfschema/include/enable_instruments.inc
new file mode 100644
index 00000000000..94d63aee941
--- /dev/null
+++ b/mysql-test/suite/perfschema/include/enable_instruments.inc
@@ -0,0 +1,23 @@
+# Tests for the performance schema
+
+# ==========================================
+# HELPER include/enable_instruments
+# ==========================================
+#
+# ==== Usage ====
+#
+# 1. Define the instrument to be enabled/disabled:
+#
+# let $pfs_instrument=<instrument>
+#
+# Where <instrument> is the instrument name with or without wildcards, e.g.
+#
+# let $pfs_instrument='%statement/sql%'
+#
+--disable_query_log ONCE
+
+eval update performance_schema.setup_instruments
+ set enabled='yes', timed='yes'
+ where name like $pfs_instrument;
+
+
diff --git a/mysql-test/suite/perfschema/include/event_aggregate_setup.inc b/mysql-test/suite/perfschema/include/event_aggregate_setup.inc
index a0103649c09..769ba5f8607 100644
--- a/mysql-test/suite/perfschema/include/event_aggregate_setup.inc
+++ b/mysql-test/suite/perfschema/include/event_aggregate_setup.inc
@@ -123,8 +123,8 @@ update performance_schema.setup_instruments set enabled='YES', timed='YES'
update performance_schema.setup_instruments set enabled='YES', timed='YES'
where name in ('statement/sql/select',
'statement/sql/insert',
- 'statement/com/',
- 'statement/com/Query',
+ 'statement/abstract/new_packet',
+ 'statement/abstract/Query',
'statement/com/Quit',
'statement/com/error');
diff --git a/mysql-test/suite/perfschema/include/rpl_statements_truncate.inc b/mysql-test/suite/perfschema/include/rpl_statements_truncate.inc
new file mode 100644
index 00000000000..afd1d31a157
--- /dev/null
+++ b/mysql-test/suite/perfschema/include/rpl_statements_truncate.inc
@@ -0,0 +1,15 @@
+# Tests for the performance schema
+
+# ==========================================
+# HELPER include/rpl_truncate_statements.inc
+# ==========================================
+
+--disable_query_log
+update performance_schema.setup_instruments set enabled='no', timed='no' where name like '%statement/%';
+truncate table performance_schema.events_waits_history_long;
+truncate table performance_schema.events_statements_summary_by_digest;
+truncate table performance_schema.events_statements_history;
+truncate table performance_schema.events_statements_history_long;
+update performance_schema.setup_instruments set enabled='yes', timed='yes' where name like '%statement/%';
+--enable_query_log
+
diff --git a/mysql-test/suite/perfschema/include/sizing_auto.inc b/mysql-test/suite/perfschema/include/sizing_auto.inc
index 1a9afeaf219..4c3451ce8b5 100644
--- a/mysql-test/suite/perfschema/include/sizing_auto.inc
+++ b/mysql-test/suite/perfschema/include/sizing_auto.inc
@@ -2,8 +2,8 @@
show variables like "table_definition_cache";
show variables like "table_open_cache";
show variables like "max_connections";
-# Results vary by platform:
-# show variables like "open_files_limit";
+# open_files_limit depends on OS configuration (ulimit -n)
+#show variables like "open_files_limit";
show variables like "%performance_schema%";
show status like "%performance_schema%";
diff --git a/mysql-test/suite/perfschema/r/binlog_edge_row.result b/mysql-test/suite/perfschema/r/binlog_edge_row.result
index 9160519921a..40595a804f7 100644
--- a/mysql-test/suite/perfschema/r/binlog_edge_row.result
+++ b/mysql-test/suite/perfschema/r/binlog_edge_row.result
@@ -78,6 +78,8 @@ performance_schema.setup_instruments.timed= 'NO';
update my_bh_table, performance_schema.setup_instruments
set my_bh_table.a = my_bh_table.a + 1,
performance_schema.setup_instruments.timed= 'NO';
+Warnings:
+Warning 1870 Row events are not logged for UPDATE statements that modify BLACKHOLE tables in row format. Table(s): 'my_bh_table.'
use test;
drop table if exists marker_multi_delete;
Warnings:
@@ -101,6 +103,8 @@ delete my_bh_table.*, performance_schema.setup_actors.*
from my_bh_table, performance_schema.setup_actors
where my_bh_table.a != 1000
or performance_schema.setup_actors.role='BAZ';
+Warnings:
+Warning 1870 Row events are not logged for DELETE statements that modify BLACKHOLE tables in row format. Table(s): 'my_bh_table.'
use test;
drop table if exists marker_end;
Warnings:
diff --git a/mysql-test/suite/perfschema/r/dml_setup_instruments.result b/mysql-test/suite/perfschema/r/dml_setup_instruments.result
index 2df89cd0823..b3de51ee007 100644
--- a/mysql-test/suite/perfschema/r/dml_setup_instruments.result
+++ b/mysql-test/suite/perfschema/r/dml_setup_instruments.result
@@ -19,6 +19,9 @@ where name like 'Wait/Synch/Rwlock/sql/%'
and name not in ('wait/synch/rwlock/sql/CRYPTO_dynlock_value::lock')
order by name limit 10;
NAME ENABLED TIMED
+wait/synch/rwlock/sql/Binlog_relay_IO_delegate::lock YES YES
+wait/synch/rwlock/sql/Binlog_storage_delegate::lock YES YES
+wait/synch/rwlock/sql/Binlog_transmit_delegate::lock YES YES
wait/synch/rwlock/sql/gtid_commit_rollback YES YES
wait/synch/rwlock/sql/LOCK_dboptions YES YES
wait/synch/rwlock/sql/LOCK_grant YES YES
@@ -26,9 +29,6 @@ wait/synch/rwlock/sql/LOCK_system_variables_hash YES YES
wait/synch/rwlock/sql/LOCK_sys_init_connect YES YES
wait/synch/rwlock/sql/LOCK_sys_init_slave YES YES
wait/synch/rwlock/sql/LOGGER::LOCK_logger YES YES
-wait/synch/rwlock/sql/MDL_context::LOCK_waiting_for YES YES
-wait/synch/rwlock/sql/MDL_lock::rwlock YES YES
-wait/synch/rwlock/sql/Query_cache_query::lock YES YES
select * from performance_schema.setup_instruments
where name like 'Wait/Synch/Cond/sql/%'
and name not in (
diff --git a/mysql-test/suite/perfschema/r/func_file_io.result b/mysql-test/suite/perfschema/r/func_file_io.result
index a71c8e601aa..d710774a1f4 100644
--- a/mysql-test/suite/perfschema/r/func_file_io.result
+++ b/mysql-test/suite/perfschema/r/func_file_io.result
@@ -3,6 +3,7 @@ UPDATE performance_schema.setup_instruments SET enabled = 'YES'
WHERE name LIKE 'wait/io/file/%';
update performance_schema.threads SET instrumented = 'YES'
WHERE PROCESSLIST_ID=connection_id();
+truncate table performance_schema.events_statements_summary_by_digest;
flush status;
DROP TABLE IF EXISTS t1;
CREATE TABLE t1 (id INT PRIMARY KEY, b CHAR(100) DEFAULT 'initial value')
diff --git a/mysql-test/suite/perfschema/r/func_mutex.result b/mysql-test/suite/perfschema/r/func_mutex.result
index fa4c585e972..60f531f42f7 100644
--- a/mysql-test/suite/perfschema/r/func_mutex.result
+++ b/mysql-test/suite/perfschema/r/func_mutex.result
@@ -2,6 +2,7 @@ UPDATE performance_schema.setup_instruments SET enabled = 'NO', timed = 'YES';
UPDATE performance_schema.setup_instruments SET enabled = 'YES'
WHERE name LIKE 'wait/synch/mutex/%'
OR name LIKE 'wait/synch/rwlock/%';
+truncate table performance_schema.events_statements_summary_by_digest;
flush status;
select NAME from performance_schema.mutex_instances
where NAME = 'wait/synch/mutex/sql/LOCK_open';
diff --git a/mysql-test/suite/perfschema/r/hostcache_ipv4_blocked.result b/mysql-test/suite/perfschema/r/hostcache_ipv4_blocked.result
index e77c2dcde6f..e0342e7acdd 100644
--- a/mysql-test/suite/perfschema/r/hostcache_ipv4_blocked.result
+++ b/mysql-test/suite/perfschema/r/hostcache_ipv4_blocked.result
@@ -23,8 +23,10 @@ User Host
select `User`, `Host` from mysql.`user` where `user` like 'santa.claus.%';
User Host
select @@global.max_connect_errors into @saved_max_connect_errors;
-set global max_connect_errors = 2;
+set global max_connect_errors = 3;
grant select on test.* to 'root'@'santa.claus.ipv4.example.com';
+create user 'quota'@'santa.claus.ipv4.example.com';
+grant select on test.* to 'quota'@'santa.claus.ipv4.example.com';
select "Con1 is alive";
Con1 is alive
Con1 is alive
@@ -32,7 +34,7 @@ select current_user();
current_user()
root@localhost
set global debug= "+d,vio_peer_addr_fake_ipv4,getnameinfo_fake_ipv4,getaddrinfo_fake_good_ipv4,native_password_bad_reply";
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv4.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 192.0.2.4
HOST santa.claus.ipv4.example.com
@@ -61,7 +63,7 @@ COUNT_LOCAL_ERRORS 0
COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv4.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 192.0.2.4
HOST santa.claus.ipv4.example.com
@@ -90,7 +92,7 @@ COUNT_LOCAL_ERRORS 0
COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv4.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 192.0.2.4
HOST santa.claus.ipv4.example.com
@@ -178,7 +180,7 @@ COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
flush hosts;
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv4.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 192.0.2.4
HOST santa.claus.ipv4.example.com
@@ -207,7 +209,215 @@ COUNT_LOCAL_ERRORS 0
COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 192.0.2.4
+HOST santa.claus.ipv4.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 2
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 2
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+set global debug= "-d,native_password_bad_reply";
+message
+Valid connection should reset SUM_CONNECT_ERROR counter
+set global debug= "+d,native_password_bad_reply";
+"Dumping performance_schema.host_cache"
+IP 192.0.2.4
+HOST santa.claus.ipv4.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 0
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 2
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 192.0.2.4
+HOST santa.claus.ipv4.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 1
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 3
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 192.0.2.4
+HOST santa.claus.ipv4.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 2
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 4
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 192.0.2.4
+HOST santa.claus.ipv4.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 3
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 5
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR HY000: Host '192.0.2.4' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'
+"Dumping performance_schema.host_cache"
+IP 192.0.2.4
+HOST santa.claus.ipv4.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 3
+COUNT_HOST_BLOCKED_ERRORS 1
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 5
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR HY000: Host '192.0.2.4' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'
+"Dumping performance_schema.host_cache"
+IP 192.0.2.4
+HOST santa.claus.ipv4.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 3
+COUNT_HOST_BLOCKED_ERRORS 2
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 5
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
revoke select on test.* from 'root'@'santa.claus.ipv4.example.com';
drop user 'root'@'santa.claus.ipv4.example.com';
+revoke select on test.* from 'quota'@'santa.claus.ipv4.example.com';
+drop user 'quota'@'santa.claus.ipv4.example.com';
set global max_connect_errors = @saved_max_connect_errors;
set global debug= default;
diff --git a/mysql-test/suite/perfschema/r/hostcache_ipv6_blocked.result b/mysql-test/suite/perfschema/r/hostcache_ipv6_blocked.result
index fa0142dad96..6fbf4108422 100644
--- a/mysql-test/suite/perfschema/r/hostcache_ipv6_blocked.result
+++ b/mysql-test/suite/perfschema/r/hostcache_ipv6_blocked.result
@@ -23,8 +23,10 @@ User Host
select `User`, `Host` from mysql.`user` where `user` like 'santa.claus.%';
User Host
select @@global.max_connect_errors into @saved_max_connect_errors;
-set global max_connect_errors = 2;
+set global max_connect_errors = 3;
grant select on test.* to 'root'@'santa.claus.ipv6.example.com';
+create user 'quota'@'santa.claus.ipv6.example.com';
+grant select on test.* to 'quota'@'santa.claus.ipv6.example.com';
select "Con1 is alive";
Con1 is alive
Con1 is alive
@@ -32,7 +34,7 @@ select current_user();
current_user()
root@localhost
set global debug= "+d,vio_peer_addr_fake_ipv6,getnameinfo_fake_ipv6,getaddrinfo_fake_good_ipv6,native_password_bad_reply";
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv6.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 2001:db8::6:6
HOST santa.claus.ipv6.example.com
@@ -61,7 +63,7 @@ COUNT_LOCAL_ERRORS 0
COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv6.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 2001:db8::6:6
HOST santa.claus.ipv6.example.com
@@ -90,7 +92,7 @@ COUNT_LOCAL_ERRORS 0
COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv6.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 2001:db8::6:6
HOST santa.claus.ipv6.example.com
@@ -178,7 +180,7 @@ COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
flush hosts;
-ERROR 28000: Access denied for user 'quota'@'santa.claus.ipv6.example.com' (using password: NO)
+ERROR 08S01: Bad handshake
"Dumping performance_schema.host_cache"
IP 2001:db8::6:6
HOST santa.claus.ipv6.example.com
@@ -207,7 +209,215 @@ COUNT_LOCAL_ERRORS 0
COUNT_UNKNOWN_ERRORS 0
FIRST_ERROR_SEEN set
LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 2001:db8::6:6
+HOST santa.claus.ipv6.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 2
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 2
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+set global debug= "-d,native_password_bad_reply";
+message
+Valid connection should reset SUM_CONNECT_ERROR counter
+set global debug= "+d,native_password_bad_reply";
+"Dumping performance_schema.host_cache"
+IP 2001:db8::6:6
+HOST santa.claus.ipv6.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 0
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 2
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 2001:db8::6:6
+HOST santa.claus.ipv6.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 1
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 3
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 2001:db8::6:6
+HOST santa.claus.ipv6.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 2
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 4
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR 08S01: Bad handshake
+"Dumping performance_schema.host_cache"
+IP 2001:db8::6:6
+HOST santa.claus.ipv6.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 3
+COUNT_HOST_BLOCKED_ERRORS 0
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 5
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR HY000: Host '2001:db8::6:6' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'
+"Dumping performance_schema.host_cache"
+IP 2001:db8::6:6
+HOST santa.claus.ipv6.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 3
+COUNT_HOST_BLOCKED_ERRORS 1
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 5
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
+ERROR HY000: Host '2001:db8::6:6' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'
+"Dumping performance_schema.host_cache"
+IP 2001:db8::6:6
+HOST santa.claus.ipv6.example.com
+HOST_VALIDATED YES
+SUM_CONNECT_ERRORS 3
+COUNT_HOST_BLOCKED_ERRORS 2
+COUNT_NAMEINFO_TRANSIENT_ERRORS 0
+COUNT_NAMEINFO_PERMANENT_ERRORS 0
+COUNT_FORMAT_ERRORS 0
+COUNT_ADDRINFO_TRANSIENT_ERRORS 0
+COUNT_ADDRINFO_PERMANENT_ERRORS 0
+COUNT_FCRDNS_ERRORS 0
+COUNT_HOST_ACL_ERRORS 0
+COUNT_NO_AUTH_PLUGIN_ERRORS 0
+COUNT_AUTH_PLUGIN_ERRORS 0
+COUNT_HANDSHAKE_ERRORS 5
+COUNT_PROXY_USER_ERRORS 0
+COUNT_PROXY_USER_ACL_ERRORS 0
+COUNT_AUTHENTICATION_ERRORS 0
+COUNT_SSL_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_ERRORS 0
+COUNT_MAX_USER_CONNECTIONS_PER_HOUR_ERRORS 0
+COUNT_DEFAULT_DATABASE_ERRORS 0
+COUNT_INIT_CONNECT_ERRORS 0
+COUNT_LOCAL_ERRORS 0
+COUNT_UNKNOWN_ERRORS 0
+FIRST_ERROR_SEEN set
+LAST_ERROR_SEEN set
revoke select on test.* from 'root'@'santa.claus.ipv6.example.com';
drop user 'root'@'santa.claus.ipv6.example.com';
+revoke select on test.* from 'quota'@'santa.claus.ipv6.example.com';
+drop user 'quota'@'santa.claus.ipv6.example.com';
set global max_connect_errors = @saved_max_connect_errors;
set global debug= default;
diff --git a/mysql-test/suite/perfschema/r/innodb_table_io.result b/mysql-test/suite/perfschema/r/innodb_table_io.result
index 9b5bd783f88..460518aeb65 100644
--- a/mysql-test/suite/perfschema/r/innodb_table_io.result
+++ b/mysql-test/suite/perfschema/r/innodb_table_io.result
@@ -106,9 +106,6 @@ wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
wait/io/table/sql/handler handler.cc: TABLE test marker insert NULL
-wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
-wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
-wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
wait/io/table/sql/handler handler.cc: TABLE test marker insert NULL
wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
wait/io/table/sql/handler handler.cc: TABLE test no_index_tab fetch NULL
diff --git a/mysql-test/suite/perfschema/r/myisam_file_io.result b/mysql-test/suite/perfschema/r/myisam_file_io.result
index 40a282d9a60..f7bb9238311 100644
--- a/mysql-test/suite/perfschema/r/myisam_file_io.result
+++ b/mysql-test/suite/perfschema/r/myisam_file_io.result
@@ -4,6 +4,7 @@ update performance_schema.setup_instruments set enabled='YES'
update performance_schema.setup_consumers
set enabled='YES';
truncate table performance_schema.events_waits_history_long;
+truncate table performance_schema.events_statements_summary_by_digest;
flush status;
drop table if exists test.no_index_tab;
create table test.no_index_tab ( a varchar(255), b int ) engine=myisam;
diff --git a/mysql-test/suite/perfschema/r/ortho_iter.result b/mysql-test/suite/perfschema/r/ortho_iter.result
index 829382e68e7..e8fd6fcc19b 100644
--- a/mysql-test/suite/perfschema/r/ortho_iter.result
+++ b/mysql-test/suite/perfschema/r/ortho_iter.result
@@ -28,7 +28,8 @@ select (instr_name like "statement/%") into is_statement;
select instr_name, is_wait, is_stage, is_statement;
select count(name)
from performance_schema.setup_instruments
-where name like (concat(instr_name, "%"))
+where (name like (concat(instr_name, "%")))
+and (not name like "%/abstract/%")
into count_expected;
set cmd_1= "select count(*) from (select distinct event_name from performance_schema.";
set cmd_2= concat(" where event_name like \"",
@@ -110,12 +111,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
@@ -639,6 +640,41 @@ status
Checking table events_waits_summary_global_by_event_name ...
Warnings:
Warning 12000 Done
+call check_instrument("statement/abstract/");
+instr_name is_wait is_stage is_statement
+statement/abstract/ 0 0 1
+status
+Checking table events_stages_summary_by_account_by_event_name ...
+status
+Checking table events_stages_summary_by_host_by_event_name ...
+status
+Checking table events_stages_summary_by_thread_by_event_name ...
+status
+Checking table events_stages_summary_by_user_by_event_name ...
+status
+Checking table events_stages_summary_global_by_event_name ...
+status
+Checking table events_statements_summary_by_account_by_event_name ...
+status
+Checking table events_statements_summary_by_host_by_event_name ...
+status
+Checking table events_statements_summary_by_thread_by_event_name ...
+status
+Checking table events_statements_summary_by_user_by_event_name ...
+status
+Checking table events_statements_summary_global_by_event_name ...
+status
+Checking table events_waits_summary_by_account_by_event_name ...
+status
+Checking table events_waits_summary_by_host_by_event_name ...
+status
+Checking table events_waits_summary_by_thread_by_event_name ...
+status
+Checking table events_waits_summary_by_user_by_event_name ...
+status
+Checking table events_waits_summary_global_by_event_name ...
+Warnings:
+Warning 12000 Done
call check_instrument("statement/");
instr_name is_wait is_stage is_statement
statement/ 0 0 1
diff --git a/mysql-test/suite/perfschema/r/pfs_upgrade_event.result b/mysql-test/suite/perfschema/r/pfs_upgrade_event.result
index f92abce1c84..65c76d8decc 100644
--- a/mysql-test/suite/perfschema/r/pfs_upgrade_event.result
+++ b/mysql-test/suite/perfschema/r/pfs_upgrade_event.result
@@ -6,59 +6,59 @@ update mysql.event set db='performance_schema' where name='user_event';
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
-ERROR 1050 (42S01) at line 156: Table 'cond_instances' already exists
-ERROR 1050 (42S01) at line 181: Table 'events_waits_current' already exists
-ERROR 1050 (42S01) at line 206: Table 'events_waits_history' already exists
-ERROR 1050 (42S01) at line 231: Table 'events_waits_history_long' already exists
-ERROR 1050 (42S01) at line 244: Table 'events_waits_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 257: Table 'events_waits_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 270: Table 'events_waits_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 284: Table 'events_waits_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 297: Table 'events_waits_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 309: Table 'events_waits_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 318: Table 'file_instances' already exists
-ERROR 1050 (42S01) at line 347: Table 'file_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 378: Table 'file_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 391: Table 'socket_instances' already exists
-ERROR 1050 (42S01) at line 421: Table 'socket_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 450: Table 'socket_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 485: Table 'host_cache' already exists
-ERROR 1050 (42S01) at line 494: Table 'mutex_instances' already exists
-ERROR 1050 (42S01) at line 508: Table 'objects_summary_global_by_type' already exists
-ERROR 1050 (42S01) at line 518: Table 'performance_timers' already exists
-ERROR 1050 (42S01) at line 528: Table 'rwlock_instances' already exists
-ERROR 1050 (42S01) at line 537: Table 'setup_actors' already exists
-ERROR 1050 (42S01) at line 545: Table 'setup_consumers' already exists
-ERROR 1050 (42S01) at line 554: Table 'setup_instruments' already exists
-ERROR 1050 (42S01) at line 565: Table 'setup_objects' already exists
-ERROR 1050 (42S01) at line 573: Table 'setup_timers' already exists
-ERROR 1050 (42S01) at line 618: Table 'table_io_waits_summary_by_index_usage' already exists
-ERROR 1050 (42S01) at line 662: Table 'table_io_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 741: Table 'table_lock_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 761: Table 'threads' already exists
-ERROR 1050 (42S01) at line 777: Table 'events_stages_current' already exists
-ERROR 1050 (42S01) at line 793: Table 'events_stages_history' already exists
-ERROR 1050 (42S01) at line 809: Table 'events_stages_history_long' already exists
-ERROR 1050 (42S01) at line 822: Table 'events_stages_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 835: Table 'events_stages_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 848: Table 'events_stages_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 862: Table 'events_stages_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 874: Table 'events_stages_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 920: Table 'events_statements_current' already exists
-ERROR 1050 (42S01) at line 966: Table 'events_statements_history' already exists
-ERROR 1050 (42S01) at line 1012: Table 'events_statements_history_long' already exists
-ERROR 1050 (42S01) at line 1044: Table 'events_statements_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 1076: Table 'events_statements_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 1108: Table 'events_statements_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 1141: Table 'events_statements_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 1172: Table 'events_statements_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 1181: Table 'hosts' already exists
-ERROR 1050 (42S01) at line 1190: Table 'users' already exists
-ERROR 1050 (42S01) at line 1200: Table 'accounts' already exists
-ERROR 1050 (42S01) at line 1235: Table 'events_statements_summary_by_digest' already exists
-ERROR 1050 (42S01) at line 1245: Table 'session_connect_attrs' already exists
-ERROR 1050 (42S01) at line 1251: Table 'session_account_connect_attrs' already exists
-ERROR 1644 (HY000) at line 1844: Unexpected content found in the performance_schema database.
+ERROR 1050 (42S01) at line 164: Table 'cond_instances' already exists
+ERROR 1050 (42S01) at line 189: Table 'events_waits_current' already exists
+ERROR 1050 (42S01) at line 214: Table 'events_waits_history' already exists
+ERROR 1050 (42S01) at line 239: Table 'events_waits_history_long' already exists
+ERROR 1050 (42S01) at line 252: Table 'events_waits_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 265: Table 'events_waits_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 278: Table 'events_waits_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 292: Table 'events_waits_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 305: Table 'events_waits_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 317: Table 'events_waits_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 326: Table 'file_instances' already exists
+ERROR 1050 (42S01) at line 355: Table 'file_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 386: Table 'file_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 399: Table 'socket_instances' already exists
+ERROR 1050 (42S01) at line 429: Table 'socket_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 458: Table 'socket_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 493: Table 'host_cache' already exists
+ERROR 1050 (42S01) at line 502: Table 'mutex_instances' already exists
+ERROR 1050 (42S01) at line 516: Table 'objects_summary_global_by_type' already exists
+ERROR 1050 (42S01) at line 526: Table 'performance_timers' already exists
+ERROR 1050 (42S01) at line 536: Table 'rwlock_instances' already exists
+ERROR 1050 (42S01) at line 545: Table 'setup_actors' already exists
+ERROR 1050 (42S01) at line 553: Table 'setup_consumers' already exists
+ERROR 1050 (42S01) at line 562: Table 'setup_instruments' already exists
+ERROR 1050 (42S01) at line 573: Table 'setup_objects' already exists
+ERROR 1050 (42S01) at line 581: Table 'setup_timers' already exists
+ERROR 1050 (42S01) at line 626: Table 'table_io_waits_summary_by_index_usage' already exists
+ERROR 1050 (42S01) at line 670: Table 'table_io_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 749: Table 'table_lock_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 769: Table 'threads' already exists
+ERROR 1050 (42S01) at line 785: Table 'events_stages_current' already exists
+ERROR 1050 (42S01) at line 801: Table 'events_stages_history' already exists
+ERROR 1050 (42S01) at line 817: Table 'events_stages_history_long' already exists
+ERROR 1050 (42S01) at line 830: Table 'events_stages_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 843: Table 'events_stages_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 856: Table 'events_stages_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 870: Table 'events_stages_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 882: Table 'events_stages_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 928: Table 'events_statements_current' already exists
+ERROR 1050 (42S01) at line 974: Table 'events_statements_history' already exists
+ERROR 1050 (42S01) at line 1020: Table 'events_statements_history_long' already exists
+ERROR 1050 (42S01) at line 1052: Table 'events_statements_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 1084: Table 'events_statements_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 1116: Table 'events_statements_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 1149: Table 'events_statements_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 1180: Table 'events_statements_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 1189: Table 'hosts' already exists
+ERROR 1050 (42S01) at line 1198: Table 'users' already exists
+ERROR 1050 (42S01) at line 1208: Table 'accounts' already exists
+ERROR 1050 (42S01) at line 1243: Table 'events_statements_summary_by_digest' already exists
+ERROR 1050 (42S01) at line 1253: Table 'session_connect_attrs' already exists
+ERROR 1050 (42S01) at line 1259: Table 'session_account_connect_attrs' already exists
+ERROR 1644 (HY000) at line 1852: Unexpected content found in the performance_schema database.
FATAL ERROR: Upgrade failed
select name from mysql.event where db='performance_schema';
name
diff --git a/mysql-test/suite/perfschema/r/pfs_upgrade_func.result b/mysql-test/suite/perfschema/r/pfs_upgrade_func.result
index 5162fa7466e..3bd4ddd9505 100644
--- a/mysql-test/suite/perfschema/r/pfs_upgrade_func.result
+++ b/mysql-test/suite/perfschema/r/pfs_upgrade_func.result
@@ -6,59 +6,59 @@ update mysql.proc set db='performance_schema' where name='user_func';
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
-ERROR 1050 (42S01) at line 156: Table 'cond_instances' already exists
-ERROR 1050 (42S01) at line 181: Table 'events_waits_current' already exists
-ERROR 1050 (42S01) at line 206: Table 'events_waits_history' already exists
-ERROR 1050 (42S01) at line 231: Table 'events_waits_history_long' already exists
-ERROR 1050 (42S01) at line 244: Table 'events_waits_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 257: Table 'events_waits_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 270: Table 'events_waits_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 284: Table 'events_waits_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 297: Table 'events_waits_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 309: Table 'events_waits_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 318: Table 'file_instances' already exists
-ERROR 1050 (42S01) at line 347: Table 'file_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 378: Table 'file_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 391: Table 'socket_instances' already exists
-ERROR 1050 (42S01) at line 421: Table 'socket_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 450: Table 'socket_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 485: Table 'host_cache' already exists
-ERROR 1050 (42S01) at line 494: Table 'mutex_instances' already exists
-ERROR 1050 (42S01) at line 508: Table 'objects_summary_global_by_type' already exists
-ERROR 1050 (42S01) at line 518: Table 'performance_timers' already exists
-ERROR 1050 (42S01) at line 528: Table 'rwlock_instances' already exists
-ERROR 1050 (42S01) at line 537: Table 'setup_actors' already exists
-ERROR 1050 (42S01) at line 545: Table 'setup_consumers' already exists
-ERROR 1050 (42S01) at line 554: Table 'setup_instruments' already exists
-ERROR 1050 (42S01) at line 565: Table 'setup_objects' already exists
-ERROR 1050 (42S01) at line 573: Table 'setup_timers' already exists
-ERROR 1050 (42S01) at line 618: Table 'table_io_waits_summary_by_index_usage' already exists
-ERROR 1050 (42S01) at line 662: Table 'table_io_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 741: Table 'table_lock_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 761: Table 'threads' already exists
-ERROR 1050 (42S01) at line 777: Table 'events_stages_current' already exists
-ERROR 1050 (42S01) at line 793: Table 'events_stages_history' already exists
-ERROR 1050 (42S01) at line 809: Table 'events_stages_history_long' already exists
-ERROR 1050 (42S01) at line 822: Table 'events_stages_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 835: Table 'events_stages_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 848: Table 'events_stages_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 862: Table 'events_stages_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 874: Table 'events_stages_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 920: Table 'events_statements_current' already exists
-ERROR 1050 (42S01) at line 966: Table 'events_statements_history' already exists
-ERROR 1050 (42S01) at line 1012: Table 'events_statements_history_long' already exists
-ERROR 1050 (42S01) at line 1044: Table 'events_statements_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 1076: Table 'events_statements_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 1108: Table 'events_statements_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 1141: Table 'events_statements_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 1172: Table 'events_statements_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 1181: Table 'hosts' already exists
-ERROR 1050 (42S01) at line 1190: Table 'users' already exists
-ERROR 1050 (42S01) at line 1200: Table 'accounts' already exists
-ERROR 1050 (42S01) at line 1235: Table 'events_statements_summary_by_digest' already exists
-ERROR 1050 (42S01) at line 1245: Table 'session_connect_attrs' already exists
-ERROR 1050 (42S01) at line 1251: Table 'session_account_connect_attrs' already exists
-ERROR 1644 (HY000) at line 1844: Unexpected content found in the performance_schema database.
+ERROR 1050 (42S01) at line 164: Table 'cond_instances' already exists
+ERROR 1050 (42S01) at line 189: Table 'events_waits_current' already exists
+ERROR 1050 (42S01) at line 214: Table 'events_waits_history' already exists
+ERROR 1050 (42S01) at line 239: Table 'events_waits_history_long' already exists
+ERROR 1050 (42S01) at line 252: Table 'events_waits_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 265: Table 'events_waits_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 278: Table 'events_waits_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 292: Table 'events_waits_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 305: Table 'events_waits_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 317: Table 'events_waits_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 326: Table 'file_instances' already exists
+ERROR 1050 (42S01) at line 355: Table 'file_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 386: Table 'file_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 399: Table 'socket_instances' already exists
+ERROR 1050 (42S01) at line 429: Table 'socket_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 458: Table 'socket_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 493: Table 'host_cache' already exists
+ERROR 1050 (42S01) at line 502: Table 'mutex_instances' already exists
+ERROR 1050 (42S01) at line 516: Table 'objects_summary_global_by_type' already exists
+ERROR 1050 (42S01) at line 526: Table 'performance_timers' already exists
+ERROR 1050 (42S01) at line 536: Table 'rwlock_instances' already exists
+ERROR 1050 (42S01) at line 545: Table 'setup_actors' already exists
+ERROR 1050 (42S01) at line 553: Table 'setup_consumers' already exists
+ERROR 1050 (42S01) at line 562: Table 'setup_instruments' already exists
+ERROR 1050 (42S01) at line 573: Table 'setup_objects' already exists
+ERROR 1050 (42S01) at line 581: Table 'setup_timers' already exists
+ERROR 1050 (42S01) at line 626: Table 'table_io_waits_summary_by_index_usage' already exists
+ERROR 1050 (42S01) at line 670: Table 'table_io_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 749: Table 'table_lock_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 769: Table 'threads' already exists
+ERROR 1050 (42S01) at line 785: Table 'events_stages_current' already exists
+ERROR 1050 (42S01) at line 801: Table 'events_stages_history' already exists
+ERROR 1050 (42S01) at line 817: Table 'events_stages_history_long' already exists
+ERROR 1050 (42S01) at line 830: Table 'events_stages_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 843: Table 'events_stages_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 856: Table 'events_stages_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 870: Table 'events_stages_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 882: Table 'events_stages_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 928: Table 'events_statements_current' already exists
+ERROR 1050 (42S01) at line 974: Table 'events_statements_history' already exists
+ERROR 1050 (42S01) at line 1020: Table 'events_statements_history_long' already exists
+ERROR 1050 (42S01) at line 1052: Table 'events_statements_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 1084: Table 'events_statements_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 1116: Table 'events_statements_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 1149: Table 'events_statements_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 1180: Table 'events_statements_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 1189: Table 'hosts' already exists
+ERROR 1050 (42S01) at line 1198: Table 'users' already exists
+ERROR 1050 (42S01) at line 1208: Table 'accounts' already exists
+ERROR 1050 (42S01) at line 1243: Table 'events_statements_summary_by_digest' already exists
+ERROR 1050 (42S01) at line 1253: Table 'session_connect_attrs' already exists
+ERROR 1050 (42S01) at line 1259: Table 'session_account_connect_attrs' already exists
+ERROR 1644 (HY000) at line 1852: Unexpected content found in the performance_schema database.
FATAL ERROR: Upgrade failed
select name from mysql.proc where db='performance_schema';
name
diff --git a/mysql-test/suite/perfschema/r/pfs_upgrade_proc.result b/mysql-test/suite/perfschema/r/pfs_upgrade_proc.result
index aa13f5cf227..574061d9b9d 100644
--- a/mysql-test/suite/perfschema/r/pfs_upgrade_proc.result
+++ b/mysql-test/suite/perfschema/r/pfs_upgrade_proc.result
@@ -6,59 +6,59 @@ update mysql.proc set db='performance_schema' where name='user_proc';
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
-ERROR 1050 (42S01) at line 156: Table 'cond_instances' already exists
-ERROR 1050 (42S01) at line 181: Table 'events_waits_current' already exists
-ERROR 1050 (42S01) at line 206: Table 'events_waits_history' already exists
-ERROR 1050 (42S01) at line 231: Table 'events_waits_history_long' already exists
-ERROR 1050 (42S01) at line 244: Table 'events_waits_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 257: Table 'events_waits_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 270: Table 'events_waits_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 284: Table 'events_waits_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 297: Table 'events_waits_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 309: Table 'events_waits_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 318: Table 'file_instances' already exists
-ERROR 1050 (42S01) at line 347: Table 'file_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 378: Table 'file_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 391: Table 'socket_instances' already exists
-ERROR 1050 (42S01) at line 421: Table 'socket_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 450: Table 'socket_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 485: Table 'host_cache' already exists
-ERROR 1050 (42S01) at line 494: Table 'mutex_instances' already exists
-ERROR 1050 (42S01) at line 508: Table 'objects_summary_global_by_type' already exists
-ERROR 1050 (42S01) at line 518: Table 'performance_timers' already exists
-ERROR 1050 (42S01) at line 528: Table 'rwlock_instances' already exists
-ERROR 1050 (42S01) at line 537: Table 'setup_actors' already exists
-ERROR 1050 (42S01) at line 545: Table 'setup_consumers' already exists
-ERROR 1050 (42S01) at line 554: Table 'setup_instruments' already exists
-ERROR 1050 (42S01) at line 565: Table 'setup_objects' already exists
-ERROR 1050 (42S01) at line 573: Table 'setup_timers' already exists
-ERROR 1050 (42S01) at line 618: Table 'table_io_waits_summary_by_index_usage' already exists
-ERROR 1050 (42S01) at line 662: Table 'table_io_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 741: Table 'table_lock_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 761: Table 'threads' already exists
-ERROR 1050 (42S01) at line 777: Table 'events_stages_current' already exists
-ERROR 1050 (42S01) at line 793: Table 'events_stages_history' already exists
-ERROR 1050 (42S01) at line 809: Table 'events_stages_history_long' already exists
-ERROR 1050 (42S01) at line 822: Table 'events_stages_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 835: Table 'events_stages_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 848: Table 'events_stages_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 862: Table 'events_stages_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 874: Table 'events_stages_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 920: Table 'events_statements_current' already exists
-ERROR 1050 (42S01) at line 966: Table 'events_statements_history' already exists
-ERROR 1050 (42S01) at line 1012: Table 'events_statements_history_long' already exists
-ERROR 1050 (42S01) at line 1044: Table 'events_statements_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 1076: Table 'events_statements_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 1108: Table 'events_statements_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 1141: Table 'events_statements_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 1172: Table 'events_statements_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 1181: Table 'hosts' already exists
-ERROR 1050 (42S01) at line 1190: Table 'users' already exists
-ERROR 1050 (42S01) at line 1200: Table 'accounts' already exists
-ERROR 1050 (42S01) at line 1235: Table 'events_statements_summary_by_digest' already exists
-ERROR 1050 (42S01) at line 1245: Table 'session_connect_attrs' already exists
-ERROR 1050 (42S01) at line 1251: Table 'session_account_connect_attrs' already exists
-ERROR 1644 (HY000) at line 1844: Unexpected content found in the performance_schema database.
+ERROR 1050 (42S01) at line 164: Table 'cond_instances' already exists
+ERROR 1050 (42S01) at line 189: Table 'events_waits_current' already exists
+ERROR 1050 (42S01) at line 214: Table 'events_waits_history' already exists
+ERROR 1050 (42S01) at line 239: Table 'events_waits_history_long' already exists
+ERROR 1050 (42S01) at line 252: Table 'events_waits_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 265: Table 'events_waits_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 278: Table 'events_waits_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 292: Table 'events_waits_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 305: Table 'events_waits_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 317: Table 'events_waits_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 326: Table 'file_instances' already exists
+ERROR 1050 (42S01) at line 355: Table 'file_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 386: Table 'file_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 399: Table 'socket_instances' already exists
+ERROR 1050 (42S01) at line 429: Table 'socket_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 458: Table 'socket_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 493: Table 'host_cache' already exists
+ERROR 1050 (42S01) at line 502: Table 'mutex_instances' already exists
+ERROR 1050 (42S01) at line 516: Table 'objects_summary_global_by_type' already exists
+ERROR 1050 (42S01) at line 526: Table 'performance_timers' already exists
+ERROR 1050 (42S01) at line 536: Table 'rwlock_instances' already exists
+ERROR 1050 (42S01) at line 545: Table 'setup_actors' already exists
+ERROR 1050 (42S01) at line 553: Table 'setup_consumers' already exists
+ERROR 1050 (42S01) at line 562: Table 'setup_instruments' already exists
+ERROR 1050 (42S01) at line 573: Table 'setup_objects' already exists
+ERROR 1050 (42S01) at line 581: Table 'setup_timers' already exists
+ERROR 1050 (42S01) at line 626: Table 'table_io_waits_summary_by_index_usage' already exists
+ERROR 1050 (42S01) at line 670: Table 'table_io_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 749: Table 'table_lock_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 769: Table 'threads' already exists
+ERROR 1050 (42S01) at line 785: Table 'events_stages_current' already exists
+ERROR 1050 (42S01) at line 801: Table 'events_stages_history' already exists
+ERROR 1050 (42S01) at line 817: Table 'events_stages_history_long' already exists
+ERROR 1050 (42S01) at line 830: Table 'events_stages_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 843: Table 'events_stages_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 856: Table 'events_stages_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 870: Table 'events_stages_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 882: Table 'events_stages_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 928: Table 'events_statements_current' already exists
+ERROR 1050 (42S01) at line 974: Table 'events_statements_history' already exists
+ERROR 1050 (42S01) at line 1020: Table 'events_statements_history_long' already exists
+ERROR 1050 (42S01) at line 1052: Table 'events_statements_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 1084: Table 'events_statements_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 1116: Table 'events_statements_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 1149: Table 'events_statements_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 1180: Table 'events_statements_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 1189: Table 'hosts' already exists
+ERROR 1050 (42S01) at line 1198: Table 'users' already exists
+ERROR 1050 (42S01) at line 1208: Table 'accounts' already exists
+ERROR 1050 (42S01) at line 1243: Table 'events_statements_summary_by_digest' already exists
+ERROR 1050 (42S01) at line 1253: Table 'session_connect_attrs' already exists
+ERROR 1050 (42S01) at line 1259: Table 'session_account_connect_attrs' already exists
+ERROR 1644 (HY000) at line 1852: Unexpected content found in the performance_schema database.
FATAL ERROR: Upgrade failed
select name from mysql.proc where db='performance_schema';
name
diff --git a/mysql-test/suite/perfschema/r/pfs_upgrade_table.result b/mysql-test/suite/perfschema/r/pfs_upgrade_table.result
index 74329c79db6..79471353063 100644
--- a/mysql-test/suite/perfschema/r/pfs_upgrade_table.result
+++ b/mysql-test/suite/perfschema/r/pfs_upgrade_table.result
@@ -8,59 +8,59 @@ user_table
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
-ERROR 1050 (42S01) at line 156: Table 'cond_instances' already exists
-ERROR 1050 (42S01) at line 181: Table 'events_waits_current' already exists
-ERROR 1050 (42S01) at line 206: Table 'events_waits_history' already exists
-ERROR 1050 (42S01) at line 231: Table 'events_waits_history_long' already exists
-ERROR 1050 (42S01) at line 244: Table 'events_waits_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 257: Table 'events_waits_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 270: Table 'events_waits_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 284: Table 'events_waits_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 297: Table 'events_waits_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 309: Table 'events_waits_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 318: Table 'file_instances' already exists
-ERROR 1050 (42S01) at line 347: Table 'file_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 378: Table 'file_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 391: Table 'socket_instances' already exists
-ERROR 1050 (42S01) at line 421: Table 'socket_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 450: Table 'socket_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 485: Table 'host_cache' already exists
-ERROR 1050 (42S01) at line 494: Table 'mutex_instances' already exists
-ERROR 1050 (42S01) at line 508: Table 'objects_summary_global_by_type' already exists
-ERROR 1050 (42S01) at line 518: Table 'performance_timers' already exists
-ERROR 1050 (42S01) at line 528: Table 'rwlock_instances' already exists
-ERROR 1050 (42S01) at line 537: Table 'setup_actors' already exists
-ERROR 1050 (42S01) at line 545: Table 'setup_consumers' already exists
-ERROR 1050 (42S01) at line 554: Table 'setup_instruments' already exists
-ERROR 1050 (42S01) at line 565: Table 'setup_objects' already exists
-ERROR 1050 (42S01) at line 573: Table 'setup_timers' already exists
-ERROR 1050 (42S01) at line 618: Table 'table_io_waits_summary_by_index_usage' already exists
-ERROR 1050 (42S01) at line 662: Table 'table_io_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 741: Table 'table_lock_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 761: Table 'threads' already exists
-ERROR 1050 (42S01) at line 777: Table 'events_stages_current' already exists
-ERROR 1050 (42S01) at line 793: Table 'events_stages_history' already exists
-ERROR 1050 (42S01) at line 809: Table 'events_stages_history_long' already exists
-ERROR 1050 (42S01) at line 822: Table 'events_stages_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 835: Table 'events_stages_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 848: Table 'events_stages_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 862: Table 'events_stages_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 874: Table 'events_stages_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 920: Table 'events_statements_current' already exists
-ERROR 1050 (42S01) at line 966: Table 'events_statements_history' already exists
-ERROR 1050 (42S01) at line 1012: Table 'events_statements_history_long' already exists
-ERROR 1050 (42S01) at line 1044: Table 'events_statements_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 1076: Table 'events_statements_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 1108: Table 'events_statements_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 1141: Table 'events_statements_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 1172: Table 'events_statements_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 1181: Table 'hosts' already exists
-ERROR 1050 (42S01) at line 1190: Table 'users' already exists
-ERROR 1050 (42S01) at line 1200: Table 'accounts' already exists
-ERROR 1050 (42S01) at line 1235: Table 'events_statements_summary_by_digest' already exists
-ERROR 1050 (42S01) at line 1245: Table 'session_connect_attrs' already exists
-ERROR 1050 (42S01) at line 1251: Table 'session_account_connect_attrs' already exists
-ERROR 1644 (HY000) at line 1844: Unexpected content found in the performance_schema database.
+ERROR 1050 (42S01) at line 164: Table 'cond_instances' already exists
+ERROR 1050 (42S01) at line 189: Table 'events_waits_current' already exists
+ERROR 1050 (42S01) at line 214: Table 'events_waits_history' already exists
+ERROR 1050 (42S01) at line 239: Table 'events_waits_history_long' already exists
+ERROR 1050 (42S01) at line 252: Table 'events_waits_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 265: Table 'events_waits_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 278: Table 'events_waits_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 292: Table 'events_waits_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 305: Table 'events_waits_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 317: Table 'events_waits_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 326: Table 'file_instances' already exists
+ERROR 1050 (42S01) at line 355: Table 'file_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 386: Table 'file_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 399: Table 'socket_instances' already exists
+ERROR 1050 (42S01) at line 429: Table 'socket_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 458: Table 'socket_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 493: Table 'host_cache' already exists
+ERROR 1050 (42S01) at line 502: Table 'mutex_instances' already exists
+ERROR 1050 (42S01) at line 516: Table 'objects_summary_global_by_type' already exists
+ERROR 1050 (42S01) at line 526: Table 'performance_timers' already exists
+ERROR 1050 (42S01) at line 536: Table 'rwlock_instances' already exists
+ERROR 1050 (42S01) at line 545: Table 'setup_actors' already exists
+ERROR 1050 (42S01) at line 553: Table 'setup_consumers' already exists
+ERROR 1050 (42S01) at line 562: Table 'setup_instruments' already exists
+ERROR 1050 (42S01) at line 573: Table 'setup_objects' already exists
+ERROR 1050 (42S01) at line 581: Table 'setup_timers' already exists
+ERROR 1050 (42S01) at line 626: Table 'table_io_waits_summary_by_index_usage' already exists
+ERROR 1050 (42S01) at line 670: Table 'table_io_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 749: Table 'table_lock_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 769: Table 'threads' already exists
+ERROR 1050 (42S01) at line 785: Table 'events_stages_current' already exists
+ERROR 1050 (42S01) at line 801: Table 'events_stages_history' already exists
+ERROR 1050 (42S01) at line 817: Table 'events_stages_history_long' already exists
+ERROR 1050 (42S01) at line 830: Table 'events_stages_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 843: Table 'events_stages_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 856: Table 'events_stages_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 870: Table 'events_stages_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 882: Table 'events_stages_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 928: Table 'events_statements_current' already exists
+ERROR 1050 (42S01) at line 974: Table 'events_statements_history' already exists
+ERROR 1050 (42S01) at line 1020: Table 'events_statements_history_long' already exists
+ERROR 1050 (42S01) at line 1052: Table 'events_statements_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 1084: Table 'events_statements_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 1116: Table 'events_statements_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 1149: Table 'events_statements_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 1180: Table 'events_statements_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 1189: Table 'hosts' already exists
+ERROR 1050 (42S01) at line 1198: Table 'users' already exists
+ERROR 1050 (42S01) at line 1208: Table 'accounts' already exists
+ERROR 1050 (42S01) at line 1243: Table 'events_statements_summary_by_digest' already exists
+ERROR 1050 (42S01) at line 1253: Table 'session_connect_attrs' already exists
+ERROR 1050 (42S01) at line 1259: Table 'session_account_connect_attrs' already exists
+ERROR 1644 (HY000) at line 1852: Unexpected content found in the performance_schema database.
FATAL ERROR: Upgrade failed
show tables like "user_table";
Tables_in_performance_schema (user_table)
diff --git a/mysql-test/suite/perfschema/r/pfs_upgrade_view.result b/mysql-test/suite/perfschema/r/pfs_upgrade_view.result
index ddc9579a513..90d44087bb0 100644
--- a/mysql-test/suite/perfschema/r/pfs_upgrade_view.result
+++ b/mysql-test/suite/perfschema/r/pfs_upgrade_view.result
@@ -8,59 +8,59 @@ user_view
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
-ERROR 1050 (42S01) at line 156: Table 'cond_instances' already exists
-ERROR 1050 (42S01) at line 181: Table 'events_waits_current' already exists
-ERROR 1050 (42S01) at line 206: Table 'events_waits_history' already exists
-ERROR 1050 (42S01) at line 231: Table 'events_waits_history_long' already exists
-ERROR 1050 (42S01) at line 244: Table 'events_waits_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 257: Table 'events_waits_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 270: Table 'events_waits_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 284: Table 'events_waits_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 297: Table 'events_waits_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 309: Table 'events_waits_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 318: Table 'file_instances' already exists
-ERROR 1050 (42S01) at line 347: Table 'file_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 378: Table 'file_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 391: Table 'socket_instances' already exists
-ERROR 1050 (42S01) at line 421: Table 'socket_summary_by_instance' already exists
-ERROR 1050 (42S01) at line 450: Table 'socket_summary_by_event_name' already exists
-ERROR 1050 (42S01) at line 485: Table 'host_cache' already exists
-ERROR 1050 (42S01) at line 494: Table 'mutex_instances' already exists
-ERROR 1050 (42S01) at line 508: Table 'objects_summary_global_by_type' already exists
-ERROR 1050 (42S01) at line 518: Table 'performance_timers' already exists
-ERROR 1050 (42S01) at line 528: Table 'rwlock_instances' already exists
-ERROR 1050 (42S01) at line 537: Table 'setup_actors' already exists
-ERROR 1050 (42S01) at line 545: Table 'setup_consumers' already exists
-ERROR 1050 (42S01) at line 554: Table 'setup_instruments' already exists
-ERROR 1050 (42S01) at line 565: Table 'setup_objects' already exists
-ERROR 1050 (42S01) at line 573: Table 'setup_timers' already exists
-ERROR 1050 (42S01) at line 618: Table 'table_io_waits_summary_by_index_usage' already exists
-ERROR 1050 (42S01) at line 662: Table 'table_io_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 741: Table 'table_lock_waits_summary_by_table' already exists
-ERROR 1050 (42S01) at line 761: Table 'threads' already exists
-ERROR 1050 (42S01) at line 777: Table 'events_stages_current' already exists
-ERROR 1050 (42S01) at line 793: Table 'events_stages_history' already exists
-ERROR 1050 (42S01) at line 809: Table 'events_stages_history_long' already exists
-ERROR 1050 (42S01) at line 822: Table 'events_stages_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 835: Table 'events_stages_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 848: Table 'events_stages_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 862: Table 'events_stages_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 874: Table 'events_stages_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 920: Table 'events_statements_current' already exists
-ERROR 1050 (42S01) at line 966: Table 'events_statements_history' already exists
-ERROR 1050 (42S01) at line 1012: Table 'events_statements_history_long' already exists
-ERROR 1050 (42S01) at line 1044: Table 'events_statements_summary_by_thread_by_event_name' already exists
-ERROR 1050 (42S01) at line 1076: Table 'events_statements_summary_by_host_by_event_name' already exists
-ERROR 1050 (42S01) at line 1108: Table 'events_statements_summary_by_user_by_event_name' already exists
-ERROR 1050 (42S01) at line 1141: Table 'events_statements_summary_by_account_by_event_name' already exists
-ERROR 1050 (42S01) at line 1172: Table 'events_statements_summary_global_by_event_name' already exists
-ERROR 1050 (42S01) at line 1181: Table 'hosts' already exists
-ERROR 1050 (42S01) at line 1190: Table 'users' already exists
-ERROR 1050 (42S01) at line 1200: Table 'accounts' already exists
-ERROR 1050 (42S01) at line 1235: Table 'events_statements_summary_by_digest' already exists
-ERROR 1050 (42S01) at line 1245: Table 'session_connect_attrs' already exists
-ERROR 1050 (42S01) at line 1251: Table 'session_account_connect_attrs' already exists
-ERROR 1644 (HY000) at line 1844: Unexpected content found in the performance_schema database.
+ERROR 1050 (42S01) at line 164: Table 'cond_instances' already exists
+ERROR 1050 (42S01) at line 189: Table 'events_waits_current' already exists
+ERROR 1050 (42S01) at line 214: Table 'events_waits_history' already exists
+ERROR 1050 (42S01) at line 239: Table 'events_waits_history_long' already exists
+ERROR 1050 (42S01) at line 252: Table 'events_waits_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 265: Table 'events_waits_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 278: Table 'events_waits_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 292: Table 'events_waits_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 305: Table 'events_waits_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 317: Table 'events_waits_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 326: Table 'file_instances' already exists
+ERROR 1050 (42S01) at line 355: Table 'file_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 386: Table 'file_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 399: Table 'socket_instances' already exists
+ERROR 1050 (42S01) at line 429: Table 'socket_summary_by_instance' already exists
+ERROR 1050 (42S01) at line 458: Table 'socket_summary_by_event_name' already exists
+ERROR 1050 (42S01) at line 493: Table 'host_cache' already exists
+ERROR 1050 (42S01) at line 502: Table 'mutex_instances' already exists
+ERROR 1050 (42S01) at line 516: Table 'objects_summary_global_by_type' already exists
+ERROR 1050 (42S01) at line 526: Table 'performance_timers' already exists
+ERROR 1050 (42S01) at line 536: Table 'rwlock_instances' already exists
+ERROR 1050 (42S01) at line 545: Table 'setup_actors' already exists
+ERROR 1050 (42S01) at line 553: Table 'setup_consumers' already exists
+ERROR 1050 (42S01) at line 562: Table 'setup_instruments' already exists
+ERROR 1050 (42S01) at line 573: Table 'setup_objects' already exists
+ERROR 1050 (42S01) at line 581: Table 'setup_timers' already exists
+ERROR 1050 (42S01) at line 626: Table 'table_io_waits_summary_by_index_usage' already exists
+ERROR 1050 (42S01) at line 670: Table 'table_io_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 749: Table 'table_lock_waits_summary_by_table' already exists
+ERROR 1050 (42S01) at line 769: Table 'threads' already exists
+ERROR 1050 (42S01) at line 785: Table 'events_stages_current' already exists
+ERROR 1050 (42S01) at line 801: Table 'events_stages_history' already exists
+ERROR 1050 (42S01) at line 817: Table 'events_stages_history_long' already exists
+ERROR 1050 (42S01) at line 830: Table 'events_stages_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 843: Table 'events_stages_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 856: Table 'events_stages_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 870: Table 'events_stages_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 882: Table 'events_stages_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 928: Table 'events_statements_current' already exists
+ERROR 1050 (42S01) at line 974: Table 'events_statements_history' already exists
+ERROR 1050 (42S01) at line 1020: Table 'events_statements_history_long' already exists
+ERROR 1050 (42S01) at line 1052: Table 'events_statements_summary_by_thread_by_event_name' already exists
+ERROR 1050 (42S01) at line 1084: Table 'events_statements_summary_by_host_by_event_name' already exists
+ERROR 1050 (42S01) at line 1116: Table 'events_statements_summary_by_user_by_event_name' already exists
+ERROR 1050 (42S01) at line 1149: Table 'events_statements_summary_by_account_by_event_name' already exists
+ERROR 1050 (42S01) at line 1180: Table 'events_statements_summary_global_by_event_name' already exists
+ERROR 1050 (42S01) at line 1189: Table 'hosts' already exists
+ERROR 1050 (42S01) at line 1198: Table 'users' already exists
+ERROR 1050 (42S01) at line 1208: Table 'accounts' already exists
+ERROR 1050 (42S01) at line 1243: Table 'events_statements_summary_by_digest' already exists
+ERROR 1050 (42S01) at line 1253: Table 'session_connect_attrs' already exists
+ERROR 1050 (42S01) at line 1259: Table 'session_account_connect_attrs' already exists
+ERROR 1644 (HY000) at line 1852: Unexpected content found in the performance_schema database.
FATAL ERROR: Upgrade failed
show tables like "user_view";
Tables_in_performance_schema (user_view)
diff --git a/mysql-test/suite/perfschema/r/privilege_table_io.result b/mysql-test/suite/perfschema/r/privilege_table_io.result
index 0bb7f03602a..ffba8643d79 100644
--- a/mysql-test/suite/perfschema/r/privilege_table_io.result
+++ b/mysql-test/suite/perfschema/r/privilege_table_io.result
@@ -41,12 +41,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/relaylog.result b/mysql-test/suite/perfschema/r/relaylog.result
index 59829db89dc..2b11019799b 100644
--- a/mysql-test/suite/perfschema/r/relaylog.result
+++ b/mysql-test/suite/perfschema/r/relaylog.result
@@ -1,7 +1,7 @@
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 see the MySQL Manual for more about this issue and possible alternatives.
+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]
drop table if exists test.t1;
reset master;
@@ -69,6 +69,7 @@ wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_index MANY
wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_log MANY
wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_sync MANY
wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_sync_queue MANY
+wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_xids NONE
"Expect no slave relay log"
select * from performance_schema.file_summary_by_instance
where event_name like "%relaylog%" order by file_name;
@@ -93,6 +94,7 @@ wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_index 0 0 0 0 0
wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_log 0 0 0 0 0
wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_sync 0 0 0 0 0
wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_sync_queue 0 0 0 0 0
+wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_xids 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;
@@ -159,6 +161,7 @@ wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_index MANY
wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_log MANY
wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_sync MANY
wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_sync_queue MANY
+wait/synch/mutex/sql/MYSQL_BIN_LOG::LOCK_xids NONE
"Expect a slave relay log"
select
substring(file_name, locate("slave-", file_name)) as FILE_NAME,
@@ -203,6 +206,7 @@ wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_done NONE
wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_flush_queue NONE
wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_index MANY
wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_log MANY
-wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_sync MANY
+wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_sync NONE
wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_sync_queue NONE
+wait/synch/mutex/sql/MYSQL_RELAY_LOG::LOCK_xids MANY
include/rpl_end.inc
diff --git a/mysql-test/suite/perfschema/r/rpl_gtid_func.result b/mysql-test/suite/perfschema/r/rpl_gtid_func.result
index 4714b63c440..c7727791eb7 100644
--- a/mysql-test/suite/perfschema/r/rpl_gtid_func.result
+++ b/mysql-test/suite/perfschema/r/rpl_gtid_func.result
@@ -1,7 +1,7 @@
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 see the MySQL Manual for more about this issue and possible alternatives.
+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]
**** On Master ****
drop table if exists test.marker;
diff --git a/mysql-test/suite/perfschema/r/rpl_statements.result b/mysql-test/suite/perfschema/r/rpl_statements.result
new file mode 100644
index 00000000000..dd8d349b989
--- /dev/null
+++ b/mysql-test/suite/perfschema/r/rpl_statements.result
@@ -0,0 +1,244 @@
+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]
+
+#
+# STEP 1 - CREATE AND REPLICATE TEST TABLES
+#
+
+**************
+*** MASTER ***
+**************
+
+*** Create test tables
+
+show variables like '%binlog_format%';
+Variable_name Value
+binlog_format MIXED
+drop table if exists test.marker;
+select thread_id into @my_thread_id
+from performance_schema.threads
+where processlist_id = connection_id();
+create table test.marker(s1 int) engine=innodb;
+**************
+*** SLAVE ***
+**************
+
+*** Clear statement events
+
+#
+# STEP 2 - REPLICATE ONE ROW ON MASTER TO GET REPLICATION THREAD ID ON SLAVE
+#
+**************
+*** MASTER ***
+**************
+
+insert into test.marker values (0);
+
+**************
+*** SLAVE ***
+**************
+
+*** Verify row, get replication thread id, clear statement events
+
+select thread_id into @slave_thread_id from performance_schema.events_statements_history
+where sql_text like '%marker%';
+*** Verify row inserted on master was replicated
+select count(*) = 1 as 'Expect 1' from test.marker;
+Expect 1
+1
+*** Clear statement events
+
+#
+# STEP 3 - PERFORM DML STATEMENTS ON MASTER
+#
+**************
+*** MASTER ***
+**************
+
+show variables like '%binlog_format%';
+Variable_name Value
+binlog_format MIXED
+*** Clear statement events
+
+*** Create/drop table, create/drop database
+
+create database marker1_db;
+create database marker2_db;
+create table marker1_db.table1 (s1 int) engine=innodb;
+create table marker2_db.table1 (s1 int) engine=innodb;
+create table marker2_db.table2 (s1 int) engine=innodb;
+
+*** Transaction
+start transaction;
+insert into marker1_db.table1 values (1), (2), (3);
+insert into marker2_db.table1 values (1), (2), (3);
+commit;
+
+*** Alter
+alter table marker1_db.table1 add column (s2 varchar(32));
+
+*** Insert, Update
+start transaction;
+insert into marker1_db.table1 values (4, 'four'), (5, 'five'), (6, 'six');
+update marker1_db.table1 set s1 = s1 + 1;
+commit;
+
+*** Rollback
+start transaction;
+insert into marker1_db.table1 values (7, 'seven'), (8, 'eight'), (9, 'nine');
+rollback;
+
+*** Autocommit, Delete, Drop
+delete from marker1_db.table1 where s1 > 4;
+drop table marker2_db.table1;
+drop database marker2_db;
+
+*** Examine statements events that will be compared on the slave
+
+select thread_id, event_id, rpad(event_name, 28, ' ') event_name, rpad(current_schema, 10, ' ') current_schema, rpad(digest_text, 72, ' ') digest_text, sql_text from performance_schema.events_statements_history_long
+where sql_text like '%marker%' order by event_id;
+thread_id event_id event_name current_schema digest_text sql_text
+[THREAD_ID] [EVENT_ID] statement/sql/create_db test CREATE SCHEMA marker1_db create database marker1_db
+[THREAD_ID] [EVENT_ID] statement/sql/create_db test CREATE SCHEMA marker2_db create database marker2_db
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker1_db . table1 ( s1 INTEGER ) ENGINE = innodb create table marker1_db.table1 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker2_db . table1 ( s1 INTEGER ) ENGINE = innodb create table marker2_db.table1 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker2_db . table2 ( s1 INTEGER ) ENGINE = innodb create table marker2_db.table2 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (?) /* , ... */ insert into marker1_db.table1 values (1), (2), (3)
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker2_db . table1 VALUES (?) /* , ... */ insert into marker2_db.table1 values (1), (2), (3)
+[THREAD_ID] [EVENT_ID] statement/sql/alter_table test ALTER TABLE marker1_db . table1 ADD COLUMN ( s2 VARCHARACTER (?) ) alter table marker1_db.table1 add column (s2 varchar(32))
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (...) /* , ... */ insert into marker1_db.table1 values (4, 'four'), (5, 'five'), (6, 'six')
+[THREAD_ID] [EVENT_ID] statement/sql/update test UPDATE marker1_db . table1 SET s1 = s1 + ? update marker1_db.table1 set s1 = s1 + 1
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (...) /* , ... */ insert into marker1_db.table1 values (7, 'seven'), (8, 'eight'), (9, 'nine')
+[THREAD_ID] [EVENT_ID] statement/sql/delete test DELETE FROM marker1_db . table1 WHERE s1 > ? delete from marker1_db.table1 where s1 > 4
+[THREAD_ID] [EVENT_ID] statement/sql/drop_table test DROP TABLE marker2_db . table1 drop table marker2_db.table1
+[THREAD_ID] [EVENT_ID] statement/sql/drop_db test DROP SCHEMA marker2_db drop database marker2_db
+
+#
+# STEP 4 - REPLICATE STATEMENT EVENTS ON MASTER TO SLAVE
+#
+
+*** Store statement events in holding table, then replicate
+
+#
+# Create table to hold statement events for later comparison on the slave
+#
+create table test.master_events_statements_history_long as
+(select thread_id, event_id, event_name, sql_text, digest, digest_text, current_schema, rows_affected
+from performance_schema.events_statements_history_long
+where (thread_id=@my_thread_id and digest_text like '%marker%'));
+
+#
+# STEP 5 - VERIFY DML AND DDL STATEMENT EVENTS ON SLAVE
+#
+**************
+*** SLAVE ***
+**************
+
+*** List statement events from master
+
+select thread_id, event_id, rpad(event_name, 28, ' ') event_name, rpad(current_schema, 10, ' ') current_schema, rpad(digest_text, 72, ' ') digest_text, sql_text from master_events_statements_history_long order by event_id;
+thread_id event_id event_name current_schema digest_text sql_text
+[THREAD_ID] [EVENT_ID] statement/sql/create_db test CREATE SCHEMA marker1_db create database marker1_db
+[THREAD_ID] [EVENT_ID] statement/sql/create_db test CREATE SCHEMA marker2_db create database marker2_db
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker1_db . table1 ( s1 INTEGER ) ENGINE = innodb create table marker1_db.table1 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker2_db . table1 ( s1 INTEGER ) ENGINE = innodb create table marker2_db.table1 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker2_db . table2 ( s1 INTEGER ) ENGINE = innodb create table marker2_db.table2 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (?) /* , ... */ insert into marker1_db.table1 values (1), (2), (3)
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker2_db . table1 VALUES (?) /* , ... */ insert into marker2_db.table1 values (1), (2), (3)
+[THREAD_ID] [EVENT_ID] statement/sql/alter_table test ALTER TABLE marker1_db . table1 ADD COLUMN ( s2 VARCHARACTER (?) ) alter table marker1_db.table1 add column (s2 varchar(32))
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (...) /* , ... */ insert into marker1_db.table1 values (4, 'four'), (5, 'five'), (6, 'six')
+[THREAD_ID] [EVENT_ID] statement/sql/update test UPDATE marker1_db . table1 SET s1 = s1 + ? update marker1_db.table1 set s1 = s1 + 1
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (...) /* , ... */ insert into marker1_db.table1 values (7, 'seven'), (8, 'eight'), (9, 'nine')
+[THREAD_ID] [EVENT_ID] statement/sql/delete test DELETE FROM marker1_db . table1 WHERE s1 > ? delete from marker1_db.table1 where s1 > 4
+[THREAD_ID] [EVENT_ID] statement/sql/drop_table test DROP TABLE marker2_db . table1 drop table marker2_db.table1
+[THREAD_ID] [EVENT_ID] statement/sql/drop_db test DROP SCHEMA marker2_db drop database marker2_db
+
+*** List statement events on slave
+
+select thread_id, event_id, rpad(event_name, 28, ' ') event_name, rpad(current_schema, 10, ' ') current_schema, rpad(digest_text, 72, ' ') digest_text, sql_text from performance_schema.events_statements_history_long
+where thread_id = @slave_thread_id and sql_text like '%marker%' order by event_id;
+thread_id event_id event_name current_schema digest_text sql_text
+[THREAD_ID] [EVENT_ID] statement/sql/create_db marker1_db CREATE SCHEMA marker1_db create database marker1_db
+[THREAD_ID] [EVENT_ID] statement/sql/create_db marker2_db CREATE SCHEMA marker2_db create database marker2_db
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker1_db . table1 ( s1 INTEGER ) ENGINE = innodb create table marker1_db.table1 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker2_db . table1 ( s1 INTEGER ) ENGINE = innodb create table marker2_db.table1 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/create_table test CREATE TABLE marker2_db . table2 ( s1 INTEGER ) ENGINE = innodb create table marker2_db.table2 (s1 int) engine=innodb
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (?) /* , ... */ insert into marker1_db.table1 values (1), (2), (3)
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker2_db . table1 VALUES (?) /* , ... */ insert into marker2_db.table1 values (1), (2), (3)
+[THREAD_ID] [EVENT_ID] statement/sql/alter_table test ALTER TABLE marker1_db . table1 ADD COLUMN ( s2 VARCHARACTER (?) ) alter table marker1_db.table1 add column (s2 varchar(32))
+[THREAD_ID] [EVENT_ID] statement/sql/insert test INSERT INTO marker1_db . table1 VALUES (...) /* , ... */ insert into marker1_db.table1 values (4, 'four'), (5, 'five'), (6, 'six')
+[THREAD_ID] [EVENT_ID] statement/sql/update test UPDATE marker1_db . table1 SET s1 = s1 + ? update marker1_db.table1 set s1 = s1 + 1
+[THREAD_ID] [EVENT_ID] statement/sql/delete test DELETE FROM marker1_db . table1 WHERE s1 > ? delete from marker1_db.table1 where s1 > 4
+[THREAD_ID] [EVENT_ID] statement/sql/drop_table test DROP TABLE `marker2_db` . `table1` DROP TABLE `marker2_db`.`table1` /* generated by server */
+[THREAD_ID] [EVENT_ID] statement/sql/drop_db marker2_db DROP SCHEMA marker2_db drop database marker2_db
+
+*** Compare master and slave events
+
+
+*** Event name comparison - expect 0 mismatches
+
+select thread_id, event_id, event_name, digest_text, sql_text from performance_schema.events_statements_history_long t1
+where t1.thread_id = @slave_thread_id and
+sql_text like '%marker%' and
+not exists (select * from master_events_statements_history_long t2 where t2.event_name = t1.event_name);
+thread_id event_id event_name digest_text sql_text
+
+*** Statement digest comparison - expect 1 mismatch for DROP TABLE
+
+select thread_id, event_id, event_name, digest, digest_text, sql_text from performance_schema.events_statements_history_long t1
+where t1.thread_id = @slave_thread_id and
+sql_text like '%marker%' and
+not exists (select * from master_events_statements_history_long t2 where t2.digest = t1.digest);
+thread_id event_id event_name digest digest_text sql_text
+[THREAD_ID] [EVENT_ID] statement/sql/drop_table [DIGEST] DROP TABLE `marker2_db` . `table1` DROP TABLE `marker2_db`.`table1` /* generated by server */
+
+#
+# STEP 6 - DISABLE REPLICATED STATEMENT EVENTS ON SLAVE
+#
+update performance_schema.setup_instruments set enabled='no', timed='no'
+ where name like '%statement/abstract/relay_log%';
+select * from performance_schema.setup_instruments where name like '%statement/abstract/relay_log%';
+NAME ENABLED TIMED
+statement/abstract/relay_log NO NO
+
+#
+# STEP 7 - UPDATE TABLES ON MASTER, REPLICATE
+#
+**************
+*** MASTER ***
+**************
+
+*** Clear statement events
+*** Update some tables, then replicate
+
+insert into marker1_db.table1 values (999, '999'), (998, '998'), (997, '997');
+
+#
+# STEP 8 - VERIFY TABLE UPDATES FROM MASTER, EXPECT NO STATEMENT EVENTS ON SLAVE
+#
+**************
+*** SLAVE ***
+**************
+
+*** Confirm rows were replicated
+
+select * from marker1_db.table1 where s1 > 900 order by s1;
+s1 s2
+997 997
+998 998
+999 999
+
+*** Confirm that are no statements events from the replication thread
+
+select * from performance_schema.events_statements_history_long
+where thread_id = @slave_thread_id;
+THREAD_ID EVENT_ID END_EVENT_ID EVENT_NAME SOURCE TIMER_START TIMER_END TIMER_WAIT LOCK_TIME SQL_TEXT DIGEST DIGEST_TEXT CURRENT_SCHEMA OBJECT_TYPE OBJECT_SCHEMA OBJECT_NAME OBJECT_INSTANCE_BEGIN MYSQL_ERRNO RETURNED_SQLSTATE MESSAGE_TEXT ERRORS WARNINGS ROWS_AFFECTED ROWS_SENT ROWS_EXAMINED CREATED_TMP_DISK_TABLES CREATED_TMP_TABLES SELECT_FULL_JOIN SELECT_FULL_RANGE_JOIN SELECT_RANGE SELECT_RANGE_CHECK SELECT_SCAN SORT_MERGE_PASSES SORT_RANGE SORT_ROWS SORT_SCAN NO_INDEX_USED NO_GOOD_INDEX_USED NESTING_EVENT_ID NESTING_EVENT_TYPE
+
+#
+# STEP 9 - CLEAN UP
+#
+
+include/rpl_end.inc
diff --git a/mysql-test/suite/perfschema/r/setup_instruments_defaults.result b/mysql-test/suite/perfschema/r/setup_instruments_defaults.result
index 531af43d798..6932d8926c9 100644
--- a/mysql-test/suite/perfschema/r/setup_instruments_defaults.result
+++ b/mysql-test/suite/perfschema/r/setup_instruments_defaults.result
@@ -1,14 +1,19 @@
+#
+# Verify that the configuration file defaults were processed correctly
+#
SELECT * FROM performance_schema.setup_instruments
WHERE name IN (
'wait/synch/mutex/sql/LOCK_user_conn',
'wait/synch/mutex/sql/LOCK_uuid_generator',
-'wait/synch/mutex/sql/LOCK_xid_cache'
- 'stage/sql/creating table')
+'wait/synch/mutex/sql/LOCK_xid_cache',
+'stage/sql/creating table')
AND enabled = 'yes' AND timed = 'no'
ORDER BY name;
NAME ENABLED TIMED
+stage/sql/creating table YES NO
wait/synch/mutex/sql/LOCK_user_conn YES NO
wait/synch/mutex/sql/LOCK_uuid_generator YES NO
+wait/synch/mutex/sql/LOCK_xid_cache YES NO
SELECT * FROM performance_schema.setup_instruments
WHERE name = 'wait/synch/mutex/sql/LOCK_thread_count'
AND enabled = 'no' AND timed = 'no';
@@ -24,13 +29,36 @@ NAME ENABLED TIMED
wait/synch/mutex/sql/LOG_INFO::lock YES YES
wait/synch/mutex/sql/THD::LOCK_thd_data YES YES
SELECT * FROM performance_schema.setup_instruments
-WHERE name IN (
-'wait/synch/mutex/sql/Delayed_insert::mutex',
-'wait/synch/mutex/sql/hash_filo::lock')
+WHERE name = 'wait/synch/mutex/sql/hash_filo::lock'
AND enabled = 'no' AND timed = 'no'
ORDER BY name;
NAME ENABLED TIMED
-wait/synch/mutex/sql/Delayed_insert::mutex NO NO
wait/synch/mutex/sql/hash_filo::lock NO NO
+#
+# Verify that the instrument startup settings are not not visible.
+#
SHOW VARIABLES LIKE "%/wait/synch/mutex%";
Variable_name Value
+#
+# Verify command line options are processed correctly
+#
+#
+# Verify that wait/io/table/sql/handler is enabled and timed
+#
+SELECT * FROM performance_schema.setup_instruments
+WHERE name like "%wait/io/table/sql/handler%";
+NAME ENABLED TIMED
+wait/io/table/sql/handler YES YES
+#
+# Stop server
+# Restart server with wait/io/table/sql/handler disabled
+# Enable reconnect
+# Wait until connected again
+# Disable reconnect
+#
+# Verify that wait/io/table is disabled
+#
+SELECT * FROM performance_schema.setup_instruments
+WHERE name like "%wait/io/table/sql/handler%";
+NAME ENABLED TIMED
+wait/io/table/sql/handler NO NO
diff --git a/mysql-test/suite/perfschema/r/sizing_default.result b/mysql-test/suite/perfschema/r/sizing_default.result
index 2a1a89dd4ba..ef7f7069c19 100644
--- a/mysql-test/suite/perfschema/r/sizing_default.result
+++ b/mysql-test/suite/perfschema/r/sizing_default.result
@@ -1,45 +1,45 @@
show variables like "table_definition_cache";
Variable_name Value
-table_definition_cache 400
+table_definition_cache 1400
show variables like "table_open_cache";
Variable_name Value
-table_open_cache 400
+table_open_cache 2000
show variables like "max_connections";
Variable_name Value
max_connections 151
show variables like "%performance_schema%";
Variable_name Value
performance_schema ON
-performance_schema_accounts_size 10
-performance_schema_digests_size 1000
-performance_schema_events_stages_history_long_size 100
-performance_schema_events_stages_history_size 5
-performance_schema_events_statements_history_long_size 100
-performance_schema_events_statements_history_size 5
-performance_schema_events_waits_history_long_size 100
-performance_schema_events_waits_history_size 5
-performance_schema_hosts_size 20
+performance_schema_accounts_size 100
+performance_schema_digests_size 10000
+performance_schema_events_stages_history_long_size 10000
+performance_schema_events_stages_history_size 10
+performance_schema_events_statements_history_long_size 10000
+performance_schema_events_statements_history_size 10
+performance_schema_events_waits_history_long_size 10000
+performance_schema_events_waits_history_size 10
+performance_schema_hosts_size 100
performance_schema_max_cond_classes 80
-performance_schema_max_cond_instances 836
+performance_schema_max_cond_instances 3504
performance_schema_max_file_classes 50
performance_schema_max_file_handles 32768
-performance_schema_max_file_instances 1556
+performance_schema_max_file_instances 7693
performance_schema_max_mutex_classes 200
-performance_schema_max_mutex_instances 3282
-performance_schema_max_rwlock_classes 30
-performance_schema_max_rwlock_instances 1724
+performance_schema_max_mutex_instances 15906
+performance_schema_max_rwlock_classes 40
+performance_schema_max_rwlock_instances 9102
performance_schema_max_socket_classes 10
-performance_schema_max_socket_instances 179
+performance_schema_max_socket_instances 322
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
-performance_schema_max_table_handles 445
-performance_schema_max_table_instances 445
+performance_schema_max_statement_classes 168
+performance_schema_max_table_handles 4000
+performance_schema_max_table_instances 12500
performance_schema_max_thread_classes 50
-performance_schema_max_thread_instances 224
+performance_schema_max_thread_instances 402
performance_schema_session_connect_attrs_size 512
performance_schema_setup_actors_size 100
performance_schema_setup_objects_size 100
-performance_schema_users_size 5
+performance_schema_users_size 100
show status like "%performance_schema%";
Variable_name Value
Performance_schema_accounts_lost 0
@@ -68,19 +68,19 @@ Performance_schema_users_lost 0
show engine performance_schema status;
Type Name Status
performance_schema events_waits_current.row_size 184
-performance_schema events_waits_current.row_count 1344
+performance_schema events_waits_current.row_count 2412
performance_schema events_waits_history.row_size 184
-performance_schema events_waits_history.row_count 1120
-performance_schema events_waits_history.memory 206080
+performance_schema events_waits_history.row_count 4020
+performance_schema events_waits_history.memory 739680
performance_schema events_waits_history_long.row_size 184
-performance_schema events_waits_history_long.row_count 100
-performance_schema events_waits_history_long.memory 18400
+performance_schema events_waits_history_long.row_count 10000
+performance_schema events_waits_history_long.memory 1840000
performance_schema (pfs_mutex_class).row_size 256
performance_schema (pfs_mutex_class).row_count 200
performance_schema (pfs_mutex_class).memory 51200
performance_schema (pfs_rwlock_class).row_size 320
-performance_schema (pfs_rwlock_class).row_count 30
-performance_schema (pfs_rwlock_class).memory 9600
+performance_schema (pfs_rwlock_class).row_count 40
+performance_schema (pfs_rwlock_class).memory 12800
performance_schema (pfs_cond_class).row_size 256
performance_schema (pfs_cond_class).row_count 80
performance_schema (pfs_cond_class).memory 20480
@@ -91,32 +91,32 @@ performance_schema (pfs_file_class).row_size 320
performance_schema (pfs_file_class).row_count 50
performance_schema (pfs_file_class).memory 16000
performance_schema mutex_instances.row_size 128
-performance_schema mutex_instances.row_count 3282
-performance_schema mutex_instances.memory 420096
+performance_schema mutex_instances.row_count 15906
+performance_schema mutex_instances.memory 2035968
performance_schema rwlock_instances.row_size 192
-performance_schema rwlock_instances.row_count 1724
-performance_schema rwlock_instances.memory 331008
+performance_schema rwlock_instances.row_count 9102
+performance_schema rwlock_instances.memory 1747584
performance_schema cond_instances.row_size 128
-performance_schema cond_instances.row_count 836
-performance_schema cond_instances.memory 107008
-performance_schema threads.row_size 1856
-performance_schema threads.row_count 224
-performance_schema threads.memory 415744
+performance_schema cond_instances.row_count 3504
+performance_schema cond_instances.memory 448512
+performance_schema threads.row_size 2816
+performance_schema threads.row_count 402
+performance_schema threads.memory 1132032
performance_schema file_instances.row_size 704
-performance_schema file_instances.row_count 1556
-performance_schema file_instances.memory 1095424
+performance_schema file_instances.row_count 7693
+performance_schema file_instances.memory 5415872
performance_schema (pfs_file_handle).row_size 8
performance_schema (pfs_file_handle).row_count 32768
performance_schema (pfs_file_handle).memory 262144
performance_schema events_waits_summary_by_thread_by_event_name.row_size 32
-performance_schema events_waits_summary_by_thread_by_event_name.row_count 83552
-performance_schema events_waits_summary_by_thread_by_event_name.memory 2673664
+performance_schema events_waits_summary_by_thread_by_event_name.row_count 153966
+performance_schema events_waits_summary_by_thread_by_event_name.memory 4926912
performance_schema (pfs_table_share).row_size 22208
-performance_schema (pfs_table_share).row_count 445
-performance_schema (pfs_table_share).memory 9882560
+performance_schema (pfs_table_share).row_count 12500
+performance_schema (pfs_table_share).memory 277600000
performance_schema (pfs_table).row_size 9280
-performance_schema (pfs_table).row_count 445
-performance_schema (pfs_table).memory 4129600
+performance_schema (pfs_table).row_count 4000
+performance_schema (pfs_table).memory 37120000
performance_schema setup_actors.row_size 256
performance_schema setup_actors.row_count 100
performance_schema setup_actors.memory 25600
@@ -124,101 +124,101 @@ performance_schema setup_objects.row_size 448
performance_schema setup_objects.row_count 100
performance_schema setup_objects.memory 44800
performance_schema (pfs_account).row_size 256
-performance_schema (pfs_account).row_count 10
-performance_schema (pfs_account).memory 2560
+performance_schema (pfs_account).row_count 100
+performance_schema (pfs_account).memory 25600
performance_schema events_waits_summary_by_account_by_event_name.row_size 32
-performance_schema events_waits_summary_by_account_by_event_name.row_count 3730
-performance_schema events_waits_summary_by_account_by_event_name.memory 119360
+performance_schema events_waits_summary_by_account_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_account_by_event_name.memory 1225600
performance_schema events_waits_summary_by_user_by_event_name.row_size 32
-performance_schema events_waits_summary_by_user_by_event_name.row_count 1865
-performance_schema events_waits_summary_by_user_by_event_name.memory 59680
+performance_schema events_waits_summary_by_user_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_user_by_event_name.memory 1225600
performance_schema events_waits_summary_by_host_by_event_name.row_size 32
-performance_schema events_waits_summary_by_host_by_event_name.row_count 7460
-performance_schema events_waits_summary_by_host_by_event_name.memory 238720
+performance_schema events_waits_summary_by_host_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_host_by_event_name.memory 1225600
performance_schema (pfs_user).row_size 128
-performance_schema (pfs_user).row_count 5
-performance_schema (pfs_user).memory 640
+performance_schema (pfs_user).row_count 100
+performance_schema (pfs_user).memory 12800
performance_schema (pfs_host).row_size 128
-performance_schema (pfs_host).row_count 20
-performance_schema (pfs_host).memory 2560
-performance_schema (pfs_stage_class).row_size 192
+performance_schema (pfs_host).row_count 100
+performance_schema (pfs_host).memory 12800
+performance_schema (pfs_stage_class).row_size 256
performance_schema (pfs_stage_class).row_count 150
-performance_schema (pfs_stage_class).memory 28800
+performance_schema (pfs_stage_class).memory 38400
performance_schema events_stages_history.row_size 88
-performance_schema events_stages_history.row_count 1120
-performance_schema events_stages_history.memory 98560
+performance_schema events_stages_history.row_count 4020
+performance_schema events_stages_history.memory 353760
performance_schema events_stages_history_long.row_size 88
-performance_schema events_stages_history_long.row_count 100
-performance_schema events_stages_history_long.memory 8800
+performance_schema events_stages_history_long.row_count 10000
+performance_schema events_stages_history_long.memory 880000
performance_schema events_stages_summary_by_thread_by_event_name.row_size 32
-performance_schema events_stages_summary_by_thread_by_event_name.row_count 33600
-performance_schema events_stages_summary_by_thread_by_event_name.memory 1075200
+performance_schema events_stages_summary_by_thread_by_event_name.row_count 60300
+performance_schema events_stages_summary_by_thread_by_event_name.memory 1929600
performance_schema events_stages_summary_global_by_event_name.row_size 32
performance_schema events_stages_summary_global_by_event_name.row_count 150
performance_schema events_stages_summary_global_by_event_name.memory 4800
performance_schema events_stages_summary_by_account_by_event_name.row_size 32
-performance_schema events_stages_summary_by_account_by_event_name.row_count 1500
-performance_schema events_stages_summary_by_account_by_event_name.memory 48000
+performance_schema events_stages_summary_by_account_by_event_name.row_count 15000
+performance_schema events_stages_summary_by_account_by_event_name.memory 480000
performance_schema events_stages_summary_by_user_by_event_name.row_size 32
-performance_schema events_stages_summary_by_user_by_event_name.row_count 750
-performance_schema events_stages_summary_by_user_by_event_name.memory 24000
+performance_schema events_stages_summary_by_user_by_event_name.row_count 15000
+performance_schema events_stages_summary_by_user_by_event_name.memory 480000
performance_schema events_stages_summary_by_host_by_event_name.row_size 32
-performance_schema events_stages_summary_by_host_by_event_name.row_count 3000
-performance_schema events_stages_summary_by_host_by_event_name.memory 96000
+performance_schema events_stages_summary_by_host_by_event_name.row_count 15000
+performance_schema events_stages_summary_by_host_by_event_name.memory 480000
performance_schema (pfs_statement_class).row_size 192
-performance_schema (pfs_statement_class).row_count 167
-performance_schema (pfs_statement_class).memory 32064
+performance_schema (pfs_statement_class).row_count 168
+performance_schema (pfs_statement_class).memory 32256
performance_schema events_statements_history.row_size 3024
-performance_schema events_statements_history.row_count 1120
-performance_schema events_statements_history.memory 3386880
+performance_schema events_statements_history.row_count 4020
+performance_schema events_statements_history.memory 12156480
performance_schema events_statements_history_long.row_size 3024
-performance_schema events_statements_history_long.row_count 100
-performance_schema events_statements_history_long.memory 302400
+performance_schema events_statements_history_long.row_count 10000
+performance_schema events_statements_history_long.memory 30240000
performance_schema events_statements_summary_by_thread_by_event_name.row_size 184
-performance_schema events_statements_summary_by_thread_by_event_name.row_count 37408
-performance_schema events_statements_summary_by_thread_by_event_name.memory 6883072
+performance_schema events_statements_summary_by_thread_by_event_name.row_count 67536
+performance_schema events_statements_summary_by_thread_by_event_name.memory 12426624
performance_schema events_statements_summary_global_by_event_name.row_size 184
-performance_schema events_statements_summary_global_by_event_name.row_count 167
-performance_schema events_statements_summary_global_by_event_name.memory 30728
+performance_schema events_statements_summary_global_by_event_name.row_count 168
+performance_schema events_statements_summary_global_by_event_name.memory 30912
performance_schema events_statements_summary_by_account_by_event_name.row_size 184
-performance_schema events_statements_summary_by_account_by_event_name.row_count 1670
-performance_schema events_statements_summary_by_account_by_event_name.memory 307280
+performance_schema events_statements_summary_by_account_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_account_by_event_name.memory 3091200
performance_schema events_statements_summary_by_user_by_event_name.row_size 184
-performance_schema events_statements_summary_by_user_by_event_name.row_count 835
-performance_schema events_statements_summary_by_user_by_event_name.memory 153640
+performance_schema events_statements_summary_by_user_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_user_by_event_name.memory 3091200
performance_schema events_statements_summary_by_host_by_event_name.row_size 184
-performance_schema events_statements_summary_by_host_by_event_name.row_count 3340
-performance_schema events_statements_summary_by_host_by_event_name.memory 614560
+performance_schema events_statements_summary_by_host_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_host_by_event_name.memory 3091200
performance_schema events_statements_current.row_size 3024
-performance_schema events_statements_current.row_count 224
-performance_schema events_statements_current.memory 677376
+performance_schema events_statements_current.row_count 402
+performance_schema events_statements_current.memory 1215648
performance_schema (pfs_socket_class).row_size 320
performance_schema (pfs_socket_class).row_count 10
performance_schema (pfs_socket_class).memory 3200
performance_schema socket_instances.row_size 320
-performance_schema socket_instances.row_count 179
-performance_schema socket_instances.memory 57280
+performance_schema socket_instances.row_count 322
+performance_schema socket_instances.memory 103040
performance_schema events_statements_summary_by_digest.row_size 1472
-performance_schema events_statements_summary_by_digest.row_count 1000
-performance_schema events_statements_summary_by_digest.memory 1472000
-performance_schema session_connect_attrs.row_size 224
+performance_schema events_statements_summary_by_digest.row_count 10000
+performance_schema events_statements_summary_by_digest.memory 14720000
+performance_schema session_connect_attrs.row_size 402
performance_schema session_connect_attrs.row_count 512
-performance_schema session_connect_attrs.memory 114688
+performance_schema session_connect_attrs.memory 205824
performance_schema (account_hash).count 2
-performance_schema (account_hash).size 10
+performance_schema (account_hash).size 100
performance_schema (digest_hash).count 0
-performance_schema (digest_hash).size 1000
+performance_schema (digest_hash).size 10000
performance_schema (filename_hash).count 0
-performance_schema (filename_hash).size 1556
+performance_schema (filename_hash).size 7693
performance_schema (host_hash).count 2
-performance_schema (host_hash).size 20
+performance_schema (host_hash).size 100
performance_schema (setup_actor_hash).count 1
performance_schema (setup_actor_hash).size 100
performance_schema (setup_object_hash).count 4
performance_schema (setup_object_hash).size 100
-performance_schema (table_share_hash).count 82
-performance_schema (table_share_hash).size 445
+performance_schema (table_share_hash).count 80
+performance_schema (table_share_hash).size 12500
performance_schema (user_hash).count 2
-performance_schema (user_hash).size 5
+performance_schema (user_hash).size 100
performance_schema host_cache.size 336
-performance_schema performance_schema.memory 35561856
+performance_schema performance_schema.memory 422231328
diff --git a/mysql-test/suite/perfschema/r/sizing_high.result b/mysql-test/suite/perfschema/r/sizing_high.result
index 6e7a1abe8a2..4d63c970782 100644
--- a/mysql-test/suite/perfschema/r/sizing_high.result
+++ b/mysql-test/suite/perfschema/r/sizing_high.result
@@ -26,12 +26,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 23385
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 52200
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 30800
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 420
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 800
performance_schema_max_table_instances 12500
performance_schema_max_thread_classes 50
@@ -79,8 +79,8 @@ performance_schema (pfs_mutex_class).row_size 256
performance_schema (pfs_mutex_class).row_count 200
performance_schema (pfs_mutex_class).memory 51200
performance_schema (pfs_rwlock_class).row_size 320
-performance_schema (pfs_rwlock_class).row_count 30
-performance_schema (pfs_rwlock_class).memory 9600
+performance_schema (pfs_rwlock_class).row_count 40
+performance_schema (pfs_rwlock_class).memory 12800
performance_schema (pfs_cond_class).row_size 256
performance_schema (pfs_cond_class).row_count 80
performance_schema (pfs_cond_class).memory 20480
@@ -99,9 +99,9 @@ performance_schema rwlock_instances.memory 5913600
performance_schema cond_instances.row_size 128
performance_schema cond_instances.row_count 10900
performance_schema cond_instances.memory 1395200
-performance_schema threads.row_size 1856
+performance_schema threads.row_size 2816
performance_schema threads.row_count 500
-performance_schema threads.memory 928000
+performance_schema threads.memory 1408000
performance_schema file_instances.row_size 704
performance_schema file_instances.row_count 23385
performance_schema file_instances.memory 16463040
@@ -109,8 +109,8 @@ performance_schema (pfs_file_handle).row_size 8
performance_schema (pfs_file_handle).row_count 32768
performance_schema (pfs_file_handle).memory 262144
performance_schema events_waits_summary_by_thread_by_event_name.row_size 32
-performance_schema events_waits_summary_by_thread_by_event_name.row_count 186500
-performance_schema events_waits_summary_by_thread_by_event_name.memory 5968000
+performance_schema events_waits_summary_by_thread_by_event_name.row_count 191500
+performance_schema events_waits_summary_by_thread_by_event_name.memory 6128000
performance_schema (pfs_table_share).row_size 22208
performance_schema (pfs_table_share).row_count 12500
performance_schema (pfs_table_share).memory 277600000
@@ -127,23 +127,23 @@ performance_schema (pfs_account).row_size 256
performance_schema (pfs_account).row_count 100
performance_schema (pfs_account).memory 25600
performance_schema events_waits_summary_by_account_by_event_name.row_size 32
-performance_schema events_waits_summary_by_account_by_event_name.row_count 37300
-performance_schema events_waits_summary_by_account_by_event_name.memory 1193600
+performance_schema events_waits_summary_by_account_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_account_by_event_name.memory 1225600
performance_schema events_waits_summary_by_user_by_event_name.row_size 32
-performance_schema events_waits_summary_by_user_by_event_name.row_count 37300
-performance_schema events_waits_summary_by_user_by_event_name.memory 1193600
+performance_schema events_waits_summary_by_user_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_user_by_event_name.memory 1225600
performance_schema events_waits_summary_by_host_by_event_name.row_size 32
-performance_schema events_waits_summary_by_host_by_event_name.row_count 37300
-performance_schema events_waits_summary_by_host_by_event_name.memory 1193600
+performance_schema events_waits_summary_by_host_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_host_by_event_name.memory 1225600
performance_schema (pfs_user).row_size 128
performance_schema (pfs_user).row_count 100
performance_schema (pfs_user).memory 12800
performance_schema (pfs_host).row_size 128
performance_schema (pfs_host).row_count 100
performance_schema (pfs_host).memory 12800
-performance_schema (pfs_stage_class).row_size 192
+performance_schema (pfs_stage_class).row_size 256
performance_schema (pfs_stage_class).row_count 150
-performance_schema (pfs_stage_class).memory 28800
+performance_schema (pfs_stage_class).memory 38400
performance_schema events_stages_history.row_size 88
performance_schema events_stages_history.row_count 5000
performance_schema events_stages_history.memory 440000
@@ -166,8 +166,8 @@ performance_schema events_stages_summary_by_host_by_event_name.row_size 32
performance_schema events_stages_summary_by_host_by_event_name.row_count 15000
performance_schema events_stages_summary_by_host_by_event_name.memory 480000
performance_schema (pfs_statement_class).row_size 192
-performance_schema (pfs_statement_class).row_count 167
-performance_schema (pfs_statement_class).memory 32064
+performance_schema (pfs_statement_class).row_count 168
+performance_schema (pfs_statement_class).memory 32256
performance_schema events_statements_history.row_size 3024
performance_schema events_statements_history.row_count 5000
performance_schema events_statements_history.memory 15120000
@@ -175,20 +175,20 @@ performance_schema events_statements_history_long.row_size 3024
performance_schema events_statements_history_long.row_count 10000
performance_schema events_statements_history_long.memory 30240000
performance_schema events_statements_summary_by_thread_by_event_name.row_size 184
-performance_schema events_statements_summary_by_thread_by_event_name.row_count 83500
-performance_schema events_statements_summary_by_thread_by_event_name.memory 15364000
+performance_schema events_statements_summary_by_thread_by_event_name.row_count 84000
+performance_schema events_statements_summary_by_thread_by_event_name.memory 15456000
performance_schema events_statements_summary_global_by_event_name.row_size 184
-performance_schema events_statements_summary_global_by_event_name.row_count 167
-performance_schema events_statements_summary_global_by_event_name.memory 30728
+performance_schema events_statements_summary_global_by_event_name.row_count 168
+performance_schema events_statements_summary_global_by_event_name.memory 30912
performance_schema events_statements_summary_by_account_by_event_name.row_size 184
-performance_schema events_statements_summary_by_account_by_event_name.row_count 16700
-performance_schema events_statements_summary_by_account_by_event_name.memory 3072800
+performance_schema events_statements_summary_by_account_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_account_by_event_name.memory 3091200
performance_schema events_statements_summary_by_user_by_event_name.row_size 184
-performance_schema events_statements_summary_by_user_by_event_name.row_count 16700
-performance_schema events_statements_summary_by_user_by_event_name.memory 3072800
+performance_schema events_statements_summary_by_user_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_user_by_event_name.memory 3091200
performance_schema events_statements_summary_by_host_by_event_name.row_size 184
-performance_schema events_statements_summary_by_host_by_event_name.row_count 16700
-performance_schema events_statements_summary_by_host_by_event_name.memory 3072800
+performance_schema events_statements_summary_by_host_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_host_by_event_name.memory 3091200
performance_schema events_statements_current.row_size 3024
performance_schema events_statements_current.row_count 500
performance_schema events_statements_current.memory 1512000
@@ -216,9 +216,9 @@ performance_schema (setup_actor_hash).count 1
performance_schema (setup_actor_hash).size 100
performance_schema (setup_object_hash).count 4
performance_schema (setup_object_hash).size 100
-performance_schema (table_share_hash).count 82
+performance_schema (table_share_hash).count 80
performance_schema (table_share_hash).size 12500
performance_schema (user_hash).count 2
performance_schema (user_hash).size 100
performance_schema host_cache.size 336
-performance_schema performance_schema.memory 421029256
+performance_schema performance_schema.memory 421925632
diff --git a/mysql-test/suite/perfschema/r/sizing_low.result b/mysql-test/suite/perfschema/r/sizing_low.result
index 19c6e36868b..d5aab2c2df3 100644
--- a/mysql-test/suite/perfschema/r/sizing_low.result
+++ b/mysql-test/suite/perfschema/r/sizing_low.result
@@ -26,12 +26,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 1556
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 2945
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 1612
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 67
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 112
performance_schema_max_table_instances 445
performance_schema_max_thread_classes 50
@@ -79,8 +79,8 @@ performance_schema (pfs_mutex_class).row_size 256
performance_schema (pfs_mutex_class).row_count 200
performance_schema (pfs_mutex_class).memory 51200
performance_schema (pfs_rwlock_class).row_size 320
-performance_schema (pfs_rwlock_class).row_count 30
-performance_schema (pfs_rwlock_class).memory 9600
+performance_schema (pfs_rwlock_class).row_count 40
+performance_schema (pfs_rwlock_class).memory 12800
performance_schema (pfs_cond_class).row_size 256
performance_schema (pfs_cond_class).row_count 80
performance_schema (pfs_cond_class).memory 20480
@@ -99,9 +99,9 @@ performance_schema rwlock_instances.memory 309504
performance_schema cond_instances.row_size 128
performance_schema cond_instances.row_count 612
performance_schema cond_instances.memory 78336
-performance_schema threads.row_size 1856
+performance_schema threads.row_size 2816
performance_schema threads.row_count 112
-performance_schema threads.memory 207872
+performance_schema threads.memory 315392
performance_schema file_instances.row_size 704
performance_schema file_instances.row_count 1556
performance_schema file_instances.memory 1095424
@@ -109,8 +109,8 @@ performance_schema (pfs_file_handle).row_size 8
performance_schema (pfs_file_handle).row_count 32768
performance_schema (pfs_file_handle).memory 262144
performance_schema events_waits_summary_by_thread_by_event_name.row_size 32
-performance_schema events_waits_summary_by_thread_by_event_name.row_count 41776
-performance_schema events_waits_summary_by_thread_by_event_name.memory 1336832
+performance_schema events_waits_summary_by_thread_by_event_name.row_count 42896
+performance_schema events_waits_summary_by_thread_by_event_name.memory 1372672
performance_schema (pfs_table_share).row_size 22208
performance_schema (pfs_table_share).row_count 445
performance_schema (pfs_table_share).memory 9882560
@@ -127,23 +127,23 @@ performance_schema (pfs_account).row_size 256
performance_schema (pfs_account).row_count 10
performance_schema (pfs_account).memory 2560
performance_schema events_waits_summary_by_account_by_event_name.row_size 32
-performance_schema events_waits_summary_by_account_by_event_name.row_count 3730
-performance_schema events_waits_summary_by_account_by_event_name.memory 119360
+performance_schema events_waits_summary_by_account_by_event_name.row_count 3830
+performance_schema events_waits_summary_by_account_by_event_name.memory 122560
performance_schema events_waits_summary_by_user_by_event_name.row_size 32
-performance_schema events_waits_summary_by_user_by_event_name.row_count 1865
-performance_schema events_waits_summary_by_user_by_event_name.memory 59680
+performance_schema events_waits_summary_by_user_by_event_name.row_count 1915
+performance_schema events_waits_summary_by_user_by_event_name.memory 61280
performance_schema events_waits_summary_by_host_by_event_name.row_size 32
-performance_schema events_waits_summary_by_host_by_event_name.row_count 7460
-performance_schema events_waits_summary_by_host_by_event_name.memory 238720
+performance_schema events_waits_summary_by_host_by_event_name.row_count 7660
+performance_schema events_waits_summary_by_host_by_event_name.memory 245120
performance_schema (pfs_user).row_size 128
performance_schema (pfs_user).row_count 5
performance_schema (pfs_user).memory 640
performance_schema (pfs_host).row_size 128
performance_schema (pfs_host).row_count 20
performance_schema (pfs_host).memory 2560
-performance_schema (pfs_stage_class).row_size 192
+performance_schema (pfs_stage_class).row_size 256
performance_schema (pfs_stage_class).row_count 150
-performance_schema (pfs_stage_class).memory 28800
+performance_schema (pfs_stage_class).memory 38400
performance_schema events_stages_history.row_size 88
performance_schema events_stages_history.row_count 560
performance_schema events_stages_history.memory 49280
@@ -166,8 +166,8 @@ performance_schema events_stages_summary_by_host_by_event_name.row_size 32
performance_schema events_stages_summary_by_host_by_event_name.row_count 3000
performance_schema events_stages_summary_by_host_by_event_name.memory 96000
performance_schema (pfs_statement_class).row_size 192
-performance_schema (pfs_statement_class).row_count 167
-performance_schema (pfs_statement_class).memory 32064
+performance_schema (pfs_statement_class).row_count 168
+performance_schema (pfs_statement_class).memory 32256
performance_schema events_statements_history.row_size 3024
performance_schema events_statements_history.row_count 560
performance_schema events_statements_history.memory 1693440
@@ -175,20 +175,20 @@ performance_schema events_statements_history_long.row_size 3024
performance_schema events_statements_history_long.row_count 100
performance_schema events_statements_history_long.memory 302400
performance_schema events_statements_summary_by_thread_by_event_name.row_size 184
-performance_schema events_statements_summary_by_thread_by_event_name.row_count 18704
-performance_schema events_statements_summary_by_thread_by_event_name.memory 3441536
+performance_schema events_statements_summary_by_thread_by_event_name.row_count 18816
+performance_schema events_statements_summary_by_thread_by_event_name.memory 3462144
performance_schema events_statements_summary_global_by_event_name.row_size 184
-performance_schema events_statements_summary_global_by_event_name.row_count 167
-performance_schema events_statements_summary_global_by_event_name.memory 30728
+performance_schema events_statements_summary_global_by_event_name.row_count 168
+performance_schema events_statements_summary_global_by_event_name.memory 30912
performance_schema events_statements_summary_by_account_by_event_name.row_size 184
-performance_schema events_statements_summary_by_account_by_event_name.row_count 1670
-performance_schema events_statements_summary_by_account_by_event_name.memory 307280
+performance_schema events_statements_summary_by_account_by_event_name.row_count 1680
+performance_schema events_statements_summary_by_account_by_event_name.memory 309120
performance_schema events_statements_summary_by_user_by_event_name.row_size 184
-performance_schema events_statements_summary_by_user_by_event_name.row_count 835
-performance_schema events_statements_summary_by_user_by_event_name.memory 153640
+performance_schema events_statements_summary_by_user_by_event_name.row_count 840
+performance_schema events_statements_summary_by_user_by_event_name.memory 154560
performance_schema events_statements_summary_by_host_by_event_name.row_size 184
-performance_schema events_statements_summary_by_host_by_event_name.row_count 3340
-performance_schema events_statements_summary_by_host_by_event_name.memory 614560
+performance_schema events_statements_summary_by_host_by_event_name.row_count 3360
+performance_schema events_statements_summary_by_host_by_event_name.memory 618240
performance_schema events_statements_current.row_size 3024
performance_schema events_statements_current.row_count 112
performance_schema events_statements_current.memory 338688
@@ -216,9 +216,9 @@ performance_schema (setup_actor_hash).count 1
performance_schema (setup_actor_hash).size 100
performance_schema (setup_object_hash).count 4
performance_schema (setup_object_hash).size 100
-performance_schema (table_share_hash).count 82
+performance_schema (table_share_hash).count 80
performance_schema (table_share_hash).size 445
performance_schema (user_hash).count 2
performance_schema (user_hash).size 5
performance_schema host_cache.size 336
-performance_schema performance_schema.memory 24576832
+performance_schema performance_schema.memory 24771616
diff --git a/mysql-test/suite/perfschema/r/sizing_med.result b/mysql-test/suite/perfschema/r/sizing_med.result
index 4fbf4ac08de..c2e7a4df4bf 100644
--- a/mysql-test/suite/perfschema/r/sizing_med.result
+++ b/mysql-test/suite/perfschema/r/sizing_med.result
@@ -26,12 +26,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 1754
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 4230
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 2222
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 232
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 573
performance_schema_max_table_instances 556
performance_schema_max_thread_classes 50
@@ -79,8 +79,8 @@ performance_schema (pfs_mutex_class).row_size 256
performance_schema (pfs_mutex_class).row_count 200
performance_schema (pfs_mutex_class).memory 51200
performance_schema (pfs_rwlock_class).row_size 320
-performance_schema (pfs_rwlock_class).row_count 30
-performance_schema (pfs_rwlock_class).memory 9600
+performance_schema (pfs_rwlock_class).row_count 40
+performance_schema (pfs_rwlock_class).memory 12800
performance_schema (pfs_cond_class).row_size 256
performance_schema (pfs_cond_class).row_count 80
performance_schema (pfs_cond_class).memory 20480
@@ -99,9 +99,9 @@ performance_schema rwlock_instances.memory 426624
performance_schema cond_instances.row_size 128
performance_schema cond_instances.row_count 1079
performance_schema cond_instances.memory 138112
-performance_schema threads.row_size 1856
+performance_schema threads.row_size 2816
performance_schema threads.row_count 289
-performance_schema threads.memory 536384
+performance_schema threads.memory 813824
performance_schema file_instances.row_size 704
performance_schema file_instances.row_count 1754
performance_schema file_instances.memory 1234816
@@ -109,8 +109,8 @@ performance_schema (pfs_file_handle).row_size 8
performance_schema (pfs_file_handle).row_count 32768
performance_schema (pfs_file_handle).memory 262144
performance_schema events_waits_summary_by_thread_by_event_name.row_size 32
-performance_schema events_waits_summary_by_thread_by_event_name.row_count 107797
-performance_schema events_waits_summary_by_thread_by_event_name.memory 3449504
+performance_schema events_waits_summary_by_thread_by_event_name.row_count 110687
+performance_schema events_waits_summary_by_thread_by_event_name.memory 3541984
performance_schema (pfs_table_share).row_size 22208
performance_schema (pfs_table_share).row_count 556
performance_schema (pfs_table_share).memory 12347648
@@ -127,23 +127,23 @@ performance_schema (pfs_account).row_size 256
performance_schema (pfs_account).row_count 100
performance_schema (pfs_account).memory 25600
performance_schema events_waits_summary_by_account_by_event_name.row_size 32
-performance_schema events_waits_summary_by_account_by_event_name.row_count 37300
-performance_schema events_waits_summary_by_account_by_event_name.memory 1193600
+performance_schema events_waits_summary_by_account_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_account_by_event_name.memory 1225600
performance_schema events_waits_summary_by_user_by_event_name.row_size 32
-performance_schema events_waits_summary_by_user_by_event_name.row_count 37300
-performance_schema events_waits_summary_by_user_by_event_name.memory 1193600
+performance_schema events_waits_summary_by_user_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_user_by_event_name.memory 1225600
performance_schema events_waits_summary_by_host_by_event_name.row_size 32
-performance_schema events_waits_summary_by_host_by_event_name.row_count 37300
-performance_schema events_waits_summary_by_host_by_event_name.memory 1193600
+performance_schema events_waits_summary_by_host_by_event_name.row_count 38300
+performance_schema events_waits_summary_by_host_by_event_name.memory 1225600
performance_schema (pfs_user).row_size 128
performance_schema (pfs_user).row_count 100
performance_schema (pfs_user).memory 12800
performance_schema (pfs_host).row_size 128
performance_schema (pfs_host).row_count 100
performance_schema (pfs_host).memory 12800
-performance_schema (pfs_stage_class).row_size 192
+performance_schema (pfs_stage_class).row_size 256
performance_schema (pfs_stage_class).row_count 150
-performance_schema (pfs_stage_class).memory 28800
+performance_schema (pfs_stage_class).memory 38400
performance_schema events_stages_history.row_size 88
performance_schema events_stages_history.row_count 2890
performance_schema events_stages_history.memory 254320
@@ -166,8 +166,8 @@ performance_schema events_stages_summary_by_host_by_event_name.row_size 32
performance_schema events_stages_summary_by_host_by_event_name.row_count 15000
performance_schema events_stages_summary_by_host_by_event_name.memory 480000
performance_schema (pfs_statement_class).row_size 192
-performance_schema (pfs_statement_class).row_count 167
-performance_schema (pfs_statement_class).memory 32064
+performance_schema (pfs_statement_class).row_count 168
+performance_schema (pfs_statement_class).memory 32256
performance_schema events_statements_history.row_size 3024
performance_schema events_statements_history.row_count 2890
performance_schema events_statements_history.memory 8739360
@@ -175,20 +175,20 @@ performance_schema events_statements_history_long.row_size 3024
performance_schema events_statements_history_long.row_count 1000
performance_schema events_statements_history_long.memory 3024000
performance_schema events_statements_summary_by_thread_by_event_name.row_size 184
-performance_schema events_statements_summary_by_thread_by_event_name.row_count 48263
-performance_schema events_statements_summary_by_thread_by_event_name.memory 8880392
+performance_schema events_statements_summary_by_thread_by_event_name.row_count 48552
+performance_schema events_statements_summary_by_thread_by_event_name.memory 8933568
performance_schema events_statements_summary_global_by_event_name.row_size 184
-performance_schema events_statements_summary_global_by_event_name.row_count 167
-performance_schema events_statements_summary_global_by_event_name.memory 30728
+performance_schema events_statements_summary_global_by_event_name.row_count 168
+performance_schema events_statements_summary_global_by_event_name.memory 30912
performance_schema events_statements_summary_by_account_by_event_name.row_size 184
-performance_schema events_statements_summary_by_account_by_event_name.row_count 16700
-performance_schema events_statements_summary_by_account_by_event_name.memory 3072800
+performance_schema events_statements_summary_by_account_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_account_by_event_name.memory 3091200
performance_schema events_statements_summary_by_user_by_event_name.row_size 184
-performance_schema events_statements_summary_by_user_by_event_name.row_count 16700
-performance_schema events_statements_summary_by_user_by_event_name.memory 3072800
+performance_schema events_statements_summary_by_user_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_user_by_event_name.memory 3091200
performance_schema events_statements_summary_by_host_by_event_name.row_size 184
-performance_schema events_statements_summary_by_host_by_event_name.row_count 16700
-performance_schema events_statements_summary_by_host_by_event_name.memory 3072800
+performance_schema events_statements_summary_by_host_by_event_name.row_count 16800
+performance_schema events_statements_summary_by_host_by_event_name.memory 3091200
performance_schema events_statements_current.row_size 3024
performance_schema events_statements_current.row_count 289
performance_schema events_statements_current.memory 873936
@@ -216,9 +216,9 @@ performance_schema (setup_actor_hash).count 1
performance_schema (setup_actor_hash).size 100
performance_schema (setup_object_hash).count 4
performance_schema (setup_object_hash).size 100
-performance_schema (table_share_hash).count 82
+performance_schema (table_share_hash).count 80
performance_schema (table_share_hash).size 556
performance_schema (user_hash).count 2
performance_schema (user_hash).size 100
performance_schema host_cache.size 336
-performance_schema performance_schema.memory 70366560
+performance_schema performance_schema.memory 70954032
diff --git a/mysql-test/suite/perfschema/r/sizing_off.result b/mysql-test/suite/perfschema/r/sizing_off.result
index 79059b7efb4..0d95a8c0f1b 100644
--- a/mysql-test/suite/perfschema/r/sizing_off.result
+++ b/mysql-test/suite/perfschema/r/sizing_off.result
@@ -17,12 +17,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances -1
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances -1
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances -1
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances -1
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles -1
performance_schema_max_table_instances -1
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_disable_idle.result b/mysql-test/suite/perfschema/r/start_server_disable_idle.result
index 9dadf114965..9f22ca75162 100644
--- a/mysql-test/suite/perfschema/r/start_server_disable_idle.result
+++ b/mysql-test/suite/perfschema/r/start_server_disable_idle.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_disable_stages.result b/mysql-test/suite/perfschema/r/start_server_disable_stages.result
index 029fe5bc77c..d73d7920cd7 100644
--- a/mysql-test/suite/perfschema/r/start_server_disable_stages.result
+++ b/mysql-test/suite/perfschema/r/start_server_disable_stages.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_disable_statements.result b/mysql-test/suite/perfschema/r/start_server_disable_statements.result
index 5333d069dbd..af5fbb00d15 100644
--- a/mysql-test/suite/perfschema/r/start_server_disable_statements.result
+++ b/mysql-test/suite/perfschema/r/start_server_disable_statements.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_disable_waits.result b/mysql-test/suite/perfschema/r/start_server_disable_waits.result
index 7742ebe4a35..92f50e0a699 100644
--- a/mysql-test/suite/perfschema/r/start_server_disable_waits.result
+++ b/mysql-test/suite/perfschema/r/start_server_disable_waits.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_innodb.result b/mysql-test/suite/perfschema/r/start_server_innodb.result
index c06877957f8..ac5d03945c2 100644
--- a/mysql-test/suite/perfschema/r/start_server_innodb.result
+++ b/mysql-test/suite/perfschema/r/start_server_innodb.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_account.result b/mysql-test/suite/perfschema/r/start_server_no_account.result
index 4da846879cb..d45e9a77910 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_account.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_account.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_cond_class.result b/mysql-test/suite/perfschema/r/start_server_no_cond_class.result
index 2495e05771a..fb7eb60c915 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_cond_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_cond_class.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_cond_inst.result b/mysql-test/suite/perfschema/r/start_server_no_cond_inst.result
index f6c8c6b23fa..3fa4ed1a43d 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_cond_inst.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_cond_inst.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_file_class.result b/mysql-test/suite/perfschema/r/start_server_no_file_class.result
index 22f157e89a1..6079cb7fbdf 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_file_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_file_class.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_file_inst.result b/mysql-test/suite/perfschema/r/start_server_no_file_inst.result
index 5af19971f83..786c8a6cb96 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_file_inst.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_file_inst.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 0
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_host.result b/mysql-test/suite/perfschema/r/start_server_no_host.result
index e3c839cdc83..26b736922fe 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_host.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_host.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_mutex_class.result b/mysql-test/suite/perfschema/r/start_server_no_mutex_class.result
index 7d0a109f275..77210f4253f 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_mutex_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_mutex_class.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 0
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_mutex_inst.result b/mysql-test/suite/perfschema/r/start_server_no_mutex_inst.result
index 0ae98d17a0e..ca2ce3114c9 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_mutex_inst.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_mutex_inst.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 0
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_rwlock_class.result b/mysql-test/suite/perfschema/r/start_server_no_rwlock_class.result
index d532f1d95a9..252c6c7f0aa 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_rwlock_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_rwlock_class.result
@@ -93,7 +93,7 @@ performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_rwlock_inst.result b/mysql-test/suite/perfschema/r/start_server_no_rwlock_inst.result
index cfece945775..e7655a314ea 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_rwlock_inst.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_rwlock_inst.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 0
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
@@ -106,7 +106,7 @@ show engine PERFORMANCE_SCHEMA status;
show status like "performance_schema%";
show variables like "performance_schema_max_rwlock_classes";
Variable_name Value
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
select count(*) > 0 from performance_schema.setup_instruments
where name like "wait/synch/rwlock/%";
count(*) > 0
diff --git a/mysql-test/suite/perfschema/r/start_server_no_setup_actors.result b/mysql-test/suite/perfschema/r/start_server_no_setup_actors.result
index cf34d7f4da7..48c0574912f 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_setup_actors.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_setup_actors.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_setup_objects.result b/mysql-test/suite/perfschema/r/start_server_no_setup_objects.result
index 72cdd2a4ba9..aecc8fa1bd0 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_setup_objects.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_setup_objects.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_socket_class.result b/mysql-test/suite/perfschema/r/start_server_no_socket_class.result
index 298eac742b9..d247a9b148d 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_socket_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_socket_class.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 0
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_socket_inst.result b/mysql-test/suite/perfschema/r/start_server_no_socket_inst.result
index c48c691a1e5..6682121bd99 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_socket_inst.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_socket_inst.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 0
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_stage_class.result b/mysql-test/suite/perfschema/r/start_server_no_stage_class.result
index fb35765784b..41275012bfa 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_stage_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_stage_class.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 0
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_stages_history.result b/mysql-test/suite/perfschema/r/start_server_no_stages_history.result
index f227ca1d8df..0e367945cfc 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_stages_history.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_stages_history.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_stages_history_long.result b/mysql-test/suite/perfschema/r/start_server_no_stages_history_long.result
index be920eae15d..aa3de1ab7cd 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_stages_history_long.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_stages_history_long.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_statement_class.result b/mysql-test/suite/perfschema/r/start_server_no_statement_class.result
index 11113ef5d7d..78fe9223ef4 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_statement_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_statement_class.result
@@ -88,7 +88,7 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
diff --git a/mysql-test/suite/perfschema/r/start_server_no_statements_history.result b/mysql-test/suite/perfschema/r/start_server_no_statements_history.result
index ad7bdfd8621..d890992ac83 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_statements_history.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_statements_history.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_statements_history_long.result b/mysql-test/suite/perfschema/r/start_server_no_statements_history_long.result
index 26917ae12ae..62b3290d7ed 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_statements_history_long.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_statements_history_long.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_table_hdl.result b/mysql-test/suite/perfschema/r/start_server_no_table_hdl.result
index 6d7e98b3900..0e5837c9eaf 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_table_hdl.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_table_hdl.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 0
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_table_inst.result b/mysql-test/suite/perfschema/r/start_server_no_table_inst.result
index 488288b0d49..72347f14160 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_table_inst.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_table_inst.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 0
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_thread_class.result b/mysql-test/suite/perfschema/r/start_server_no_thread_class.result
index 3ff4ad4c967..e5dd500c316 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_thread_class.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_thread_class.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 0
diff --git a/mysql-test/suite/perfschema/r/start_server_no_thread_inst.result b/mysql-test/suite/perfschema/r/start_server_no_thread_inst.result
index 9dbd82481b3..d36c2b30441 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_thread_inst.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_thread_inst.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_user.result b/mysql-test/suite/perfschema/r/start_server_no_user.result
index 4a32b5f64dc..89efe84d938 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_user.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_user.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_waits_history.result b/mysql-test/suite/perfschema/r/start_server_no_waits_history.result
index a8db4e9facc..81e999bc0ee 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_waits_history.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_waits_history.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_no_waits_history_long.result b/mysql-test/suite/perfschema/r/start_server_no_waits_history_long.result
index 15290249ae2..bca3594c225 100644
--- a/mysql-test/suite/perfschema/r/start_server_no_waits_history_long.result
+++ b/mysql-test/suite/perfschema/r/start_server_no_waits_history_long.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_off.result b/mysql-test/suite/perfschema/r/start_server_off.result
index 1ee789b6f7c..f5249dc2039 100644
--- a/mysql-test/suite/perfschema/r/start_server_off.result
+++ b/mysql-test/suite/perfschema/r/start_server_off.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/start_server_on.result b/mysql-test/suite/perfschema/r/start_server_on.result
index c06877957f8..ac5d03945c2 100644
--- a/mysql-test/suite/perfschema/r/start_server_on.result
+++ b/mysql-test/suite/perfschema/r/start_server_on.result
@@ -88,12 +88,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_global_2u_2t.result b/mysql-test/suite/perfschema/r/table_aggregate_global_2u_2t.result
index 362136696e0..e59a03324dd 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_global_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_global_2u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_global_2u_3t.result b/mysql-test/suite/perfschema/r/table_aggregate_global_2u_3t.result
index 2c906396f4c..bb1fc975cd9 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_global_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_global_2u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_global_4u_2t.result b/mysql-test/suite/perfschema/r/table_aggregate_global_4u_2t.result
index f5a5cbf3c38..ae067698e2d 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_global_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_global_4u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_global_4u_3t.result b/mysql-test/suite/perfschema/r/table_aggregate_global_4u_3t.result
index fef1343d76a..333d3844867 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_global_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_global_4u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_2t.result b/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_2t.result
index cac68b459bf..61af4a203c9 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_2t.result
@@ -56,12 +56,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_3t.result b/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_3t.result
index 713b14bbce8..ba109d45783 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_hist_2u_3t.result
@@ -55,12 +55,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_2t.result b/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_2t.result
index 9cddb9d309f..f19d737061d 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_2t.result
@@ -56,12 +56,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_3t.result b/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_3t.result
index 8f1dff97c2f..05c4be28be3 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_hist_4u_3t.result
@@ -55,12 +55,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_off.result b/mysql-test/suite/perfschema/r/table_aggregate_off.result
index 00aea8a6773..50935c7afbe 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_off.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_off.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_2t.result b/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_2t.result
index 87fec96f45a..83345b6edda 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_3t.result b/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_3t.result
index 00c2c8c13c9..b53f0696f56 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_thread_2u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_2t.result b/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_2t.result
index edc3c4de062..3b8f6326031 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_3t.result b/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_3t.result
index 0cc1cf417a5..023ff3760c7 100644
--- a/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_aggregate_thread_4u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_2t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_2t.result
index c162505fd97..df42b39c726 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_3t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_3t.result
index 897df97a07d..30b48d59253 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_global_2u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_2t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_2t.result
index 5f192271112..4804265562c 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_3t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_3t.result
index 9aebdcf9e3b..086957fa25e 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_global_4u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_2t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_2t.result
index add84e004bb..08356e894da 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_3t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_3t.result
index 69a2cb891e7..e60acb62ff7 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_2u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_2t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_2t.result
index 77ddae26b33..5593fd8ec85 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_3t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_3t.result
index b82579cc782..0fd700c86ac 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_hist_4u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_2t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_2t.result
index 21f443f1343..c4c98c1143f 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_3t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_3t.result
index 3b54bd4a37b..3563e7bb366 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_2u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_2t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_2t.result
index 3243cfbbe32..0cf5970111d 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_3t.result b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_3t.result
index 09666783a25..c94d2192f22 100644
--- a/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_io_aggregate_thread_4u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_2t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_2t.result
index 55c8f2a2d22..84074f4d0ce 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_3t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_3t.result
index 521a0505c62..413b70c17bd 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_2u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_2t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_2t.result
index 0f105eb59b8..dfa300a09ed 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_3t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_3t.result
index c37d794f4d7..b4ca5202558 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_global_4u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_2t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_2t.result
index 5c0f82e07a5..50aeea5363a 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_3t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_3t.result
index a5dea0b24d2..eeea805e941 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_2u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_2t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_2t.result
index d0cbc4ade9f..ce9e0aeff85 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_2t.result
@@ -58,12 +58,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_3t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_3t.result
index 41619c0b145..2ecd7d56411 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_hist_4u_3t.result
@@ -57,12 +57,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_2t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_2t.result
index 28cbc4bfb0b..372ed695675 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_3t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_3t.result
index 30e7b7d7f81..3f1e78a46da 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_2u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_2t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_2t.result
index a4699ce7a7c..d88e8f4d49a 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_2t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_2t.result
@@ -60,12 +60,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_3t.result b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_3t.result
index 4970077987c..7b90426f3f8 100644
--- a/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_3t.result
+++ b/mysql-test/suite/perfschema/r/table_lock_aggregate_thread_4u_3t.result
@@ -59,12 +59,12 @@ performance_schema_max_file_handles 32768
performance_schema_max_file_instances 10000
performance_schema_max_mutex_classes 200
performance_schema_max_mutex_instances 5000
-performance_schema_max_rwlock_classes 30
+performance_schema_max_rwlock_classes 40
performance_schema_max_rwlock_instances 5000
performance_schema_max_socket_classes 10
performance_schema_max_socket_instances 1000
performance_schema_max_stage_classes 150
-performance_schema_max_statement_classes 167
+performance_schema_max_statement_classes 168
performance_schema_max_table_handles 1000
performance_schema_max_table_instances 500
performance_schema_max_thread_classes 50
diff --git a/mysql-test/suite/perfschema/t/aggregate.test b/mysql-test/suite/perfschema/t/aggregate.test
index 672737ae2a7..326c0e763d9 100644
--- a/mysql-test/suite/perfschema/t/aggregate.test
+++ b/mysql-test/suite/perfschema/t/aggregate.test
@@ -3,6 +3,7 @@
--source include/not_embedded.inc
--source include/have_perfschema.inc
+--source include/have_QC_Disabled.inc
--echo "General cleanup"
diff --git a/mysql-test/suite/perfschema/t/disabled.def b/mysql-test/suite/perfschema/t/disabled.def
index d7d43ccaefc..888298bbb09 100644
--- a/mysql-test/suite/perfschema/t/disabled.def
+++ b/mysql-test/suite/perfschema/t/disabled.def
@@ -9,6 +9,3 @@
# Do not use any TAB characters for whitespace.
#
##############################################################################
-hostcache_ipv4_max_con : BUG#14627287 27th Sept, 2012 Mayank
-hostcache_ipv6_max_con : BUG#14627287 27th Sept, 2012 Mayank
-
diff --git a/mysql-test/suite/perfschema/t/event_aggregate.test b/mysql-test/suite/perfschema/t/event_aggregate.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/event_aggregate_no_a.test b/mysql-test/suite/perfschema/t/event_aggregate_no_a.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate_no_a.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate_no_a.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_h.test b/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_h.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_h.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_h.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u.test b/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u_no_h.test b/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u_no_h.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u_no_h.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate_no_a_no_u_no_h.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/event_aggregate_no_h.test b/mysql-test/suite/perfschema/t/event_aggregate_no_h.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate_no_h.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate_no_h.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/event_aggregate_no_u.test b/mysql-test/suite/perfschema/t/event_aggregate_no_u.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate_no_u.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate_no_u.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/event_aggregate_no_u_no_h.test b/mysql-test/suite/perfschema/t/event_aggregate_no_u_no_h.test
index c1a895ec549..2f49fc40190 100644
--- a/mysql-test/suite/perfschema/t/event_aggregate_no_u_no_h.test
+++ b/mysql-test/suite/perfschema/t/event_aggregate_no_u_no_h.test
@@ -4,4 +4,4 @@
--source ../include/event_aggregate_setup.inc
--source ../include/event_aggregate_load.inc
--source ../include/event_aggregate_cleanup.inc
-
+--source include/have_QC_Disabled.inc
diff --git a/mysql-test/suite/perfschema/t/func_file_io.test b/mysql-test/suite/perfschema/t/func_file_io.test
index 014ab5e0731..2055fa9a008 100644
--- a/mysql-test/suite/perfschema/t/func_file_io.test
+++ b/mysql-test/suite/perfschema/t/func_file_io.test
@@ -16,6 +16,7 @@ update performance_schema.threads SET instrumented = 'YES'
WHERE PROCESSLIST_ID=connection_id();
# reset lost counters
+truncate table performance_schema.events_statements_summary_by_digest;
flush status;
--disable_warnings
diff --git a/mysql-test/suite/perfschema/t/func_mutex.test b/mysql-test/suite/perfschema/t/func_mutex.test
index f8f85274b93..3b0803eaedb 100644
--- a/mysql-test/suite/perfschema/t/func_mutex.test
+++ b/mysql-test/suite/perfschema/t/func_mutex.test
@@ -14,6 +14,7 @@ WHERE name LIKE 'wait/synch/mutex/%'
OR name LIKE 'wait/synch/rwlock/%';
# reset lost counters
+truncate table performance_schema.events_statements_summary_by_digest;
flush status;
# Make sure objects are instrumented
diff --git a/mysql-test/suite/perfschema/t/hostcache_ipv4_blocked.test b/mysql-test/suite/perfschema/t/hostcache_ipv4_blocked.test
index 2699121ff62..612efd18a82 100644
--- a/mysql-test/suite/perfschema/t/hostcache_ipv4_blocked.test
+++ b/mysql-test/suite/perfschema/t/hostcache_ipv4_blocked.test
@@ -18,10 +18,13 @@
select @@global.max_connect_errors into @saved_max_connect_errors;
-set global max_connect_errors = 2;
+set global max_connect_errors = 3;
grant select on test.* to 'root'@'santa.claus.ipv4.example.com';
+create user 'quota'@'santa.claus.ipv4.example.com';
+grant select on test.* to 'quota'@'santa.claus.ipv4.example.com';
+
connect (con1,"127.0.0.1",root,,test,$MASTER_MYPORT,);
select "Con1 is alive";
select current_user();
@@ -31,7 +34,7 @@ disconnect con1;
set global debug= "+d,vio_peer_addr_fake_ipv4,getnameinfo_fake_ipv4,getaddrinfo_fake_good_ipv4,native_password_bad_reply";
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
+--error ER_HANDSHAKE_ERROR
connect (con2a,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
@@ -39,7 +42,7 @@ connect (con2a,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
--source ../include/hostcache_dump.inc
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
+--error ER_HANDSHAKE_ERROR
connect (con2b,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
@@ -47,7 +50,7 @@ connect (con2b,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
--source ../include/hostcache_dump.inc
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
+--error ER_HANDSHAKE_ERROR
connect (con2c,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
@@ -74,8 +77,71 @@ connect (con2e,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
flush hosts;
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
-connect (con2c,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+--error ER_HANDSHAKE_ERROR
+connect (con3a,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con3b,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--connection default
+set global debug= "-d,native_password_bad_reply";
+
+--disable_query_log
+connect (con4,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+select "Valid connection should reset SUM_CONNECT_ERROR counter" as message;
+--disconnect con4
+--enable_query_log
+
+--connection default
+set global debug= "+d,native_password_bad_reply";
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con5a,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con5b,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con5c,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HOST_IS_BLOCKED
+connect (con5d,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HOST_IS_BLOCKED
+connect (con5e,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
--connection default
@@ -84,6 +150,9 @@ connect (con2c,"127.0.0.1",quota,,test,$MASTER_MYPORT,);
revoke select on test.* from 'root'@'santa.claus.ipv4.example.com';
drop user 'root'@'santa.claus.ipv4.example.com';
+revoke select on test.* from 'quota'@'santa.claus.ipv4.example.com';
+drop user 'quota'@'santa.claus.ipv4.example.com';
+
set global max_connect_errors = @saved_max_connect_errors;
set global debug= default;
diff --git a/mysql-test/suite/perfschema/t/hostcache_ipv6_blocked.test b/mysql-test/suite/perfschema/t/hostcache_ipv6_blocked.test
index b80efc222dc..e6d2c168a16 100644
--- a/mysql-test/suite/perfschema/t/hostcache_ipv6_blocked.test
+++ b/mysql-test/suite/perfschema/t/hostcache_ipv6_blocked.test
@@ -19,10 +19,13 @@
select @@global.max_connect_errors into @saved_max_connect_errors;
-set global max_connect_errors = 2;
+set global max_connect_errors = 3;
grant select on test.* to 'root'@'santa.claus.ipv6.example.com';
+create user 'quota'@'santa.claus.ipv6.example.com';
+grant select on test.* to 'quota'@'santa.claus.ipv6.example.com';
+
connect (con1,"::1",root,,test,$MASTER_MYPORT,);
select "Con1 is alive";
select current_user();
@@ -32,7 +35,7 @@ disconnect con1;
set global debug= "+d,vio_peer_addr_fake_ipv6,getnameinfo_fake_ipv6,getaddrinfo_fake_good_ipv6,native_password_bad_reply";
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
+--error ER_HANDSHAKE_ERROR
connect (con2a,"::1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
@@ -40,7 +43,7 @@ connect (con2a,"::1",quota,,test,$MASTER_MYPORT,);
--source ../include/hostcache_dump.inc
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
+--error ER_HANDSHAKE_ERROR
connect (con2b,"::1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
@@ -48,7 +51,7 @@ connect (con2b,"::1",quota,,test,$MASTER_MYPORT,);
--source ../include/hostcache_dump.inc
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
+--error ER_HANDSHAKE_ERROR
connect (con2c,"::1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
@@ -75,8 +78,71 @@ connect (con2e,"::1",quota,,test,$MASTER_MYPORT,);
flush hosts;
--disable_query_log
---error ER_ACCESS_DENIED_ERROR
-connect (con2c,"::1",quota,,test,$MASTER_MYPORT,);
+--error ER_HANDSHAKE_ERROR
+connect (con3a,"::1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con3b,"::1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--connection default
+set global debug= "-d,native_password_bad_reply";
+
+--disable_query_log
+connect (con4,"::1",quota,,test,$MASTER_MYPORT,);
+select "Valid connection should reset SUM_CONNECT_ERROR counter" as message;
+--disconnect con4
+--enable_query_log
+
+--connection default
+set global debug= "+d,native_password_bad_reply";
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con5a,"::1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con5b,"::1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HANDSHAKE_ERROR
+connect (con5c,"::1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HOST_IS_BLOCKED
+connect (con5d,"::1",quota,,test,$MASTER_MYPORT,);
+--enable_query_log
+
+--connection default
+--source ../include/hostcache_dump.inc
+
+--disable_query_log
+--error ER_HOST_IS_BLOCKED
+connect (con5e,"::1",quota,,test,$MASTER_MYPORT,);
--enable_query_log
--connection default
@@ -85,6 +151,9 @@ connect (con2c,"::1",quota,,test,$MASTER_MYPORT,);
revoke select on test.* from 'root'@'santa.claus.ipv6.example.com';
drop user 'root'@'santa.claus.ipv6.example.com';
+revoke select on test.* from 'quota'@'santa.claus.ipv6.example.com';
+drop user 'quota'@'santa.claus.ipv6.example.com';
+
set global max_connect_errors = @saved_max_connect_errors;
set global debug= default;
diff --git a/mysql-test/suite/perfschema/t/myisam_file_io.test b/mysql-test/suite/perfschema/t/myisam_file_io.test
index 5888c29fe22..786ae88e8b9 100644
--- a/mysql-test/suite/perfschema/t/myisam_file_io.test
+++ b/mysql-test/suite/perfschema/t/myisam_file_io.test
@@ -15,6 +15,7 @@ update performance_schema.setup_consumers
truncate table performance_schema.events_waits_history_long;
# Reset lost counters to a known state
+truncate table performance_schema.events_statements_summary_by_digest;
flush status;
# Code to test
diff --git a/mysql-test/suite/perfschema/t/nesting.test b/mysql-test/suite/perfschema/t/nesting.test
index 9b1458dca5d..4535e0e04f7 100644
--- a/mysql-test/suite/perfschema/t/nesting.test
+++ b/mysql-test/suite/perfschema/t/nesting.test
@@ -7,6 +7,7 @@
--source include/not_windows.inc
--source ../include/no_protocol.inc
--source ../include/wait_for_pfs_thread_count.inc
+--source include/have_QC_Disabled.inc
--disable_query_log
@@ -45,11 +46,12 @@ update performance_schema.setup_instruments set enabled='YES', timed='YES'
update performance_schema.setup_instruments set enabled='YES', timed='YES'
where name in ('statement/sql/select',
- 'statement/com/',
- 'statement/com/Query',
+ 'statement/abstract/new_packet',
+ 'statement/abstract/Query',
'statement/com/error');
# Start from a known clean state, to avoid noise from previous tests
+truncate table performance_schema.events_statements_summary_by_digest;
flush tables;
flush status;
diff --git a/mysql-test/suite/perfschema/t/ortho_iter.test b/mysql-test/suite/perfschema/t/ortho_iter.test
index 09ecfa8a788..0856e266386 100644
--- a/mysql-test/suite/perfschema/t/ortho_iter.test
+++ b/mysql-test/suite/perfschema/t/ortho_iter.test
@@ -44,7 +44,8 @@ begin
select count(name)
from performance_schema.setup_instruments
- where name like (concat(instr_name, "%"))
+ where (name like (concat(instr_name, "%")))
+ and (not name like "%/abstract/%")
into count_expected;
set cmd_1= "select count(*) from (select distinct event_name from performance_schema.";
@@ -138,6 +139,7 @@ call check_instrument("wait/");
call check_instrument("stage/");
call check_instrument("statement/com/");
call check_instrument("statement/sql/");
+call check_instrument("statement/abstract/");
call check_instrument("statement/");
call check_instrument("idle/io/socket");
call check_instrument("idle/");
diff --git a/mysql-test/suite/perfschema/t/rpl_statements-master.opt b/mysql-test/suite/perfschema/t/rpl_statements-master.opt
new file mode 100644
index 00000000000..01cf3e0520f
--- /dev/null
+++ b/mysql-test/suite/perfschema/t/rpl_statements-master.opt
@@ -0,0 +1 @@
+--binlog-format=mixed
diff --git a/mysql-test/suite/perfschema/t/rpl_statements-slave.opt b/mysql-test/suite/perfschema/t/rpl_statements-slave.opt
new file mode 100644
index 00000000000..01cf3e0520f
--- /dev/null
+++ b/mysql-test/suite/perfschema/t/rpl_statements-slave.opt
@@ -0,0 +1 @@
+--binlog-format=mixed
diff --git a/mysql-test/suite/perfschema/t/rpl_statements.test b/mysql-test/suite/perfschema/t/rpl_statements.test
new file mode 100644
index 00000000000..8e719610ba9
--- /dev/null
+++ b/mysql-test/suite/perfschema/t/rpl_statements.test
@@ -0,0 +1,338 @@
+#
+# Check statement instrumentation of replicated statements
+#
+--source include/not_embedded.inc
+--source include/have_perfschema.inc
+--source ../include/no_protocol.inc
+--source include/have_binlog_format_mixed.inc
+--source include/master-slave.inc
+
+#==============================================================
+# Execute a variety of dml and ddl statements on the master.
+# Verify that the corresponding statement events are generated
+# on the slave.
+#
+# 1. Setup test files on master
+# 2. Replicate test files to slave
+# 3. Perform dml and ddl statements on master
+# 4. Copy statement events on master into a temporary table
+# 4. Replicate to slave
+# 5. Compare statement events on slave to those from the master
+# 6. Disable statement/abstract/relay_log on slave
+# 7. Update some tables on the master then replicate
+# 8. Verify that the updates were replicated but no statement
+# events were recorded
+#==============================================================
+
+#
+# UTILITY QUERIES
+#
+let $get_thread_id=
+ select thread_id into @my_thread_id
+ from performance_schema.threads
+ where processlist_id = connection_id();
+
+let $disable_instruments=
+ update performance_schema.setup_instruments
+ set enabled='no', timed='no'
+ where name like '%statement/%';
+
+let $enable_instruments= ../include
+ update performance_schema.setup_instruments
+ set enabled='yes', timed='yes'
+ where name like '%statement/%';
+
+let $column_list=
+ thread_id, event_id, rpad(event_name, 28, ' ') event_name, rpad(current_schema, 10, ' ') current_schema, rpad(digest_text, 72, ' ') digest_text, sql_text;
+
+# Define instrument name for enable/disable instruments
+let $pfs_instrument='%statement/%';
+
+--echo
+--echo #
+--echo # STEP 1 - CREATE AND REPLICATE TEST TABLES
+--echo #
+
+connection master;
+
+--echo
+--echo **************
+--echo *** MASTER ***
+--echo **************
+--echo
+--echo *** Create test tables
+--echo
+
+show variables like '%binlog_format%';
+
+--disable_warnings
+drop table if exists test.marker;
+--enable_warnings
+
+eval $get_thread_id;
+
+create table test.marker(s1 int) engine=innodb;
+
+sync_slave_with_master;
+
+--echo **************
+--echo *** SLAVE ***
+--echo **************
+--echo
+--echo *** Clear statement events
+--source ../include/rpl_statements_truncate.inc
+
+--echo
+--echo #
+--echo # STEP 2 - REPLICATE ONE ROW ON MASTER TO GET REPLICATION THREAD ID ON SLAVE
+--echo #
+
+connection master;
+
+--echo **************
+--echo *** MASTER ***
+--echo **************
+--echo
+insert into test.marker values (0);
+--echo
+
+sync_slave_with_master;
+
+--echo **************
+--echo *** SLAVE ***
+--echo **************
+--echo
+--echo *** Verify row, get replication thread id, clear statement events
+--echo
+
+# TODO: Get slave thread id from threads using thread/sql/slave_sql event name
+
+select thread_id into @slave_thread_id from performance_schema.events_statements_history
+ where sql_text like '%marker%';
+let $slave_thread_id= `select @slave_thread_id`;
+
+--echo *** Verify row inserted on master was replicated
+select count(*) = 1 as 'Expect 1' from test.marker;
+
+--echo *** Clear statement events
+--source ../include/rpl_statements_truncate.inc
+
+--echo
+--echo #
+--echo # STEP 3 - PERFORM DML STATEMENTS ON MASTER
+--echo #
+
+connection master;
+
+--echo **************
+--echo *** MASTER ***
+--echo **************
+--echo
+show variables like '%binlog_format%';
+
+--echo *** Clear statement events
+--source ../include/rpl_statements_truncate.inc
+
+--echo
+--echo *** Create/drop table, create/drop database
+--echo
+create database marker1_db;
+create database marker2_db;
+create table marker1_db.table1 (s1 int) engine=innodb;
+create table marker2_db.table1 (s1 int) engine=innodb;
+create table marker2_db.table2 (s1 int) engine=innodb;
+
+--echo
+--echo *** Transaction
+start transaction;
+insert into marker1_db.table1 values (1), (2), (3);
+insert into marker2_db.table1 values (1), (2), (3);
+commit;
+
+--echo
+--echo *** Alter
+alter table marker1_db.table1 add column (s2 varchar(32));
+
+--echo
+--echo *** Insert, Update
+start transaction;
+insert into marker1_db.table1 values (4, 'four'), (5, 'five'), (6, 'six');
+update marker1_db.table1 set s1 = s1 + 1;
+commit;
+
+--echo
+--echo *** Rollback
+start transaction;
+insert into marker1_db.table1 values (7, 'seven'), (8, 'eight'), (9, 'nine');
+rollback;
+
+--echo
+--echo *** Autocommit, Delete, Drop
+delete from marker1_db.table1 where s1 > 4;
+drop table marker2_db.table1;
+drop database marker2_db;
+
+--source ../include/disable_instruments.inc
+
+--echo
+--echo *** Examine statements events that will be compared on the slave
+--echo
+
+--replace_column 1 [THREAD_ID] 2 [EVENT_ID]
+
+eval select $column_list from performance_schema.events_statements_history_long
+ where sql_text like '%marker%' order by event_id;
+
+--echo
+--echo #
+--echo # STEP 4 - REPLICATE STATEMENT EVENTS ON MASTER TO SLAVE
+--echo #
+--echo
+--echo *** Store statement events in holding table, then replicate
+--echo
+
+--source ../include/disable_instruments.inc
+
+--echo #
+--echo # Create table to hold statement events for later comparison on the slave
+--echo #
+
+create table test.master_events_statements_history_long as
+ (select thread_id, event_id, event_name, sql_text, digest, digest_text, current_schema, rows_affected
+ from performance_schema.events_statements_history_long
+ where (thread_id=@my_thread_id and digest_text like '%marker%'));
+
+--source ../include/enable_instruments.inc
+
+--echo
+--echo #
+--echo # STEP 5 - VERIFY DML AND DDL STATEMENT EVENTS ON SLAVE
+--echo #
+
+sync_slave_with_master;
+
+--echo **************
+--echo *** SLAVE ***
+--echo **************
+
+--source ../include/disable_instruments.inc
+
+--echo
+--echo *** List statement events from master
+--echo
+--replace_column 1 [THREAD_ID] 2 [EVENT_ID]
+eval select $column_list from master_events_statements_history_long order by event_id;
+
+--echo
+--echo *** List statement events on slave
+--echo
+
+--replace_column 1 [THREAD_ID] 2 [EVENT_ID]
+
+eval select $column_list from performance_schema.events_statements_history_long
+ where thread_id = @slave_thread_id and sql_text like '%marker%' order by event_id;
+
+--echo
+--echo *** Compare master and slave events
+--echo
+
+# Note: The statement digest provides a more robust comparison than the
+# event name. However, in some cases, e.g. DROP TABLE, the server generates
+# its own version of the statement which includes additional quotes and a
+# comment. A digest comparison is therefore impractical for server-generated
+# statements, so we use both methods to ensure coverage.
+
+--echo
+--echo *** Event name comparison - expect 0 mismatches
+--echo
+
+select thread_id, event_id, event_name, digest_text, sql_text from performance_schema.events_statements_history_long t1
+ where t1.thread_id = @slave_thread_id and
+ sql_text like '%marker%' and
+ not exists (select * from master_events_statements_history_long t2 where t2.event_name = t1.event_name);
+
+--echo
+--echo *** Statement digest comparison - expect 1 mismatch for DROP TABLE
+--echo
+
+--replace_column 1 [THREAD_ID] 2 [EVENT_ID] 4 [DIGEST]
+
+select thread_id, event_id, event_name, digest, digest_text, sql_text from performance_schema.events_statements_history_long t1
+ where t1.thread_id = @slave_thread_id and
+ sql_text like '%marker%' and
+ not exists (select * from master_events_statements_history_long t2 where t2.digest = t1.digest);
+
+--echo
+--echo #
+--echo # STEP 6 - DISABLE REPLICATED STATEMENT EVENTS ON SLAVE
+--echo #
+--source ../include/rpl_statements_truncate.inc
+--source ../include/enable_instruments.inc
+
+update performance_schema.setup_instruments set enabled='no', timed='no'
+ where name like '%statement/abstract/relay_log%';
+
+select * from performance_schema.setup_instruments where name like '%statement/abstract/relay_log%';
+
+--echo
+--echo #
+--echo # STEP 7 - UPDATE TABLES ON MASTER, REPLICATE
+--echo #
+
+connection master;
+
+--echo **************
+--echo *** MASTER ***
+--echo **************
+--echo
+--echo *** Clear statement events
+--source ../include/rpl_statements_truncate.inc
+
+--echo *** Update some tables, then replicate
+--echo
+
+insert into marker1_db.table1 values (999, '999'), (998, '998'), (997, '997');
+
+--echo
+--echo #
+--echo # STEP 8 - VERIFY TABLE UPDATES FROM MASTER, EXPECT NO STATEMENT EVENTS ON SLAVE
+--echo #
+
+sync_slave_with_master;
+
+--echo **************
+--echo *** SLAVE ***
+--echo **************
+--echo
+--echo *** Confirm rows were replicated
+--echo
+
+select * from marker1_db.table1 where s1 > 900 order by s1;
+
+--echo
+--echo *** Confirm that are no statements events from the replication thread
+--echo
+
+select * from performance_schema.events_statements_history_long
+ where thread_id = @slave_thread_id;
+
+--source ../include/enable_instruments.inc
+
+--echo
+--echo #
+--echo # STEP 9 - CLEAN UP
+--echo #
+--echo
+--disable_query_log
+--disable_warnings
+
+connection master;
+drop table test.marker;
+drop table test.master_events_statements_history_long;
+drop database marker1_db;
+
+sync_slave_with_master;
+
+--enable_warnings
+--enable_query_log
+--source include/rpl_end.inc
diff --git a/mysql-test/suite/perfschema/t/setup_instruments_defaults-master.opt b/mysql-test/suite/perfschema/t/setup_instruments_defaults-master.opt
index 71106aaaed0..eec7d4af545 100644
--- a/mysql-test/suite/perfschema/t/setup_instruments_defaults-master.opt
+++ b/mysql-test/suite/perfschema/t/setup_instruments_defaults-master.opt
@@ -1,21 +1,30 @@
+--no-console
--log-error=0
--loose-performance-schema-instrument='%=ON'
+--loose-performance-schema-instrument=''
+--loose-performance-schema-instrument=' wait/synch/mutex/sql/% = OFF ''
+--loose-performance-schema-instrument='//wait/synch/mutex/sql/% = 'OFF ''
+--loose-performance-schema-instrument=' wait/synch/mutex/sql/% = OFF '
+--loose-performance-schema-instrument='''''
+--loose-performance-schema-instrument=' / '
+--loose-performance-schema-instrument=' wait/synch/mutex/sql/% = OFF '
--loose-performance-schema-instrument='wait/synch/mutex/sql/% = OFF '
--loose-performance-schema-instrument='wait/synch/mutex/sql/LOCK% = ON'
---loose-performance-schema-instrument='wait/synch/mutex/sql/LOCK_thread_count = OFF'
+--loose-performance-schema-instrument='wait/synch/mutex/sql/LOCK_thread_count=OFF'
--loose-performance-schema-instrument=' wait/synch/mutex/sql/LOCK_user_conn = COUNTED'
---loose-performance-schema-instrument='wait%/synch/mutex/sql/LOCK_uu%_genera%/ = COUNTED'
---loose-performance-schema-instrument='%%wait/synch/mutex/sql/LOCK_xid_cache = COUNTED'
+--loose-performance-schema-instrument='wait%/synch/mutex/sql/LOCK_uu%_genera%/= COUNTED'
+--loose-performance-schema-instrument='%%wait/synch/mutex/sql/LOCK_xid_cache=COUNTED'
--loose-performance-schema-instrument='%=FOO'
--loose-performance-schema-instrument='%=%'
--loose-performance-schema-instrument='%'
---loose-performance-schema-instrument=''
--loose-performance-schema-instrument=' unknown%instrument/event/name with blanks = YES'
---loose-performance-schema-instrument='unknown/instrument/event/name = TRUE'
---loose-performance-schema-instrument='stage/sql/creating table = COUNTED'
---loose-performance-schema-instrument='wait/synch/mutex/sql/LOG_INFO::lock = 1'
---loose-performance-schema-instrument='wait/synch/mutex/sql/Delayed_insert::mutex = 0'
---loose-performance-schema-instrument='wait/synch/mutex/sql/THD::LOCK_thd_data = TRUE'
---loose-performance-schema-instrument='wait/synch/mutex/sql/hash_filo::lock = FALSE'
+--loose-performance-schema-instrument='unknown/instrument/event/name = TRUE'
+--loose-performance-schema-instrument='stage/sql/creating table = COUNTED'
+--loose-performance-schema-instrument='wait/synch/mutex/sql/LOG_INFO::lock = 1'
+--loose-performance-schema-instrument='wait/synch/mutex/sql/THD::LOCK_thd_data= TRUE'
+--loose-performance-schema-instrument='wait/synch/mutex/sql/hash_filo::lock =FALSE'
--loose-performance-schema-instrument='wait/synch/mutex/sql/TABLE_SHARE::LOCK_ha_data= NO'
+
+
+
diff --git a/mysql-test/suite/perfschema/t/setup_instruments_defaults.test b/mysql-test/suite/perfschema/t/setup_instruments_defaults.test
index b84b082c484..cfddfd9f1e6 100644
--- a/mysql-test/suite/perfschema/t/setup_instruments_defaults.test
+++ b/mysql-test/suite/perfschema/t/setup_instruments_defaults.test
@@ -4,14 +4,18 @@
--source include/have_perfschema.inc
# Verify that the configuration options were applied correctly to the
-# setup_instruments table. These instruments that are known to persist across
+# performance_schema.setup_instruments table. These instruments that are known to persist across
# platforms and the various compile options.
+--echo #
+--echo # Verify that the configuration file defaults were processed correctly
+--echo #
+
SELECT * FROM performance_schema.setup_instruments
WHERE name IN (
'wait/synch/mutex/sql/LOCK_user_conn',
'wait/synch/mutex/sql/LOCK_uuid_generator',
- 'wait/synch/mutex/sql/LOCK_xid_cache'
+ 'wait/synch/mutex/sql/LOCK_xid_cache',
'stage/sql/creating table')
AND enabled = 'yes' AND timed = 'no'
ORDER BY name;
@@ -28,13 +32,52 @@ AND enabled = 'yes' AND timed = 'yes'
ORDER BY name;
SELECT * FROM performance_schema.setup_instruments
-WHERE name IN (
- 'wait/synch/mutex/sql/Delayed_insert::mutex',
- 'wait/synch/mutex/sql/hash_filo::lock')
+WHERE name = 'wait/synch/mutex/sql/hash_filo::lock'
AND enabled = 'no' AND timed = 'no'
ORDER BY name;
-#
-# Verify that the instrument startup settings are not not visible.
-#
-SHOW VARIABLES LIKE "%/wait/synch/mutex%"; \ No newline at end of file
+--echo #
+--echo # Verify that the instrument startup settings are not not visible.
+--echo #
+SHOW VARIABLES LIKE "%/wait/synch/mutex%";
+
+--echo #
+--echo # Verify command line options are processed correctly
+--echo #
+
+# The instrument wait/io/table/sql/handler should be enabled and timed. We will
+# restart the server with the instrument disabled from the command line.
+--echo #
+--echo # Verify that wait/io/table/sql/handler is enabled and timed
+--echo #
+SELECT * FROM performance_schema.setup_instruments
+WHERE name like "%wait/io/table/sql/handler%";
+
+# Write file to make mysql-test-run.pl wait for the server to stop
+--exec echo "wait" > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
+
+# Restart the server
+--echo #
+--echo # Stop server
+--send_shutdown
+--echo # Restart server with wait/io/table/sql/handler disabled
+
+--exec echo "restart:--loose-performance-schema-instrument='%wait/io/table/sql/%=off'" > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
+
+# Turn on reconnect
+--echo # Enable reconnect
+--enable_reconnect
+
+# Wait for server to be back online again
+--echo # Wait until connected again
+--source include/wait_until_connected_again.inc
+
+# Turn off reconnect again
+--echo # Disable reconnect
+--disable_reconnect
+
+--echo #
+--echo # Verify that wait/io/table is disabled
+--echo #
+SELECT * FROM performance_schema.setup_instruments
+WHERE name like "%wait/io/table/sql/handler%";
diff --git a/mysql-test/suite/perfschema/t/sizing_default.cnf b/mysql-test/suite/perfschema/t/sizing_default.cnf
index 1e99e180b79..6a929998329 100644
--- a/mysql-test/suite/perfschema/t/sizing_default.cnf
+++ b/mysql-test/suite/perfschema/t/sizing_default.cnf
@@ -4,10 +4,13 @@
[mysqld.1]
# Default values used in the server, out of the box
-table_definition_cache=400
-table_open_cache=400
-max_connections=151
-open_files_limit=1024
+# open_files_limit can be scaled down based on the os configuration (ulimit -n),
+# so to get a stable test output, make sure ulimit -n is big enough
+#
+# What is supposed to happen here by default:
+# table_open_cache = 2000
+# table_definition_cache = 400 + 2000/2 = 1400
+# max_connections = 151
# Automated sizing for everything
diff --git a/mysql-test/suite/perfschema/t/sizing_default.test b/mysql-test/suite/perfschema/t/sizing_default.test
index 4d02d41aecd..d5fb8be9f77 100644
--- a/mysql-test/suite/perfschema/t/sizing_default.test
+++ b/mysql-test/suite/perfschema/t/sizing_default.test
@@ -5,5 +5,27 @@
--source include/not_valgrind.inc
--source ../include/have_aligned_memory.inc
+# Skip test if not defaults is used.
+let $max_open_files_limit= `SELECT @@open_files_limit < 5000`;
+if ($max_open_files_limit)
+{
+ skip Need open_files_limit to be at least 5000;
+}
+let $max_table_open_cache= `SELECT @@table_open_cache != 2000`;
+if ($max_table_open_cache)
+{
+ skip Need table_open_cache to be exactly 2000;
+}
+let $max_table_definition_cache= `SELECT @@table_definition_cache != 1400`;
+if ($max_table_definition_cache)
+{
+ skip Need table_definition_cache to be exactly 1400;
+}
+let $max_connections= `SELECT @@max_connections != 151`;
+if ($max_connections)
+{
+ skip Need max_connections to be exactly 151;
+}
+
--source ../include/sizing_auto.inc
diff --git a/mysql-test/suite/perfschema/t/view_table_io.test b/mysql-test/suite/perfschema/t/view_table_io.test
index 703f5414ba4..f8e545e094e 100644
--- a/mysql-test/suite/perfschema/t/view_table_io.test
+++ b/mysql-test/suite/perfschema/t/view_table_io.test
@@ -6,6 +6,7 @@
--source include/not_embedded.inc
--source include/have_perfschema.inc
--source ../include/table_io_setup_helper.inc
+--source include/have_QC_Disabled.inc
let $engine_type= MyISAM;
let $table_item= test.v1;