mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
merge of mysql-5.5 into mysql-5.5-wl1054
This commit is contained in:
@ -25,17 +25,17 @@ update performance_schema.SETUP_CONSUMERS set enabled='YES';
|
||||
|
||||
connect (con1, localhost, root, , );
|
||||
|
||||
let $con1_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con1_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID in (select connection_id())`;
|
||||
|
||||
connect (con2, localhost, root, , );
|
||||
|
||||
let $con2_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con2_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID in (select connection_id())`;
|
||||
|
||||
connect (con3, localhost, root, , );
|
||||
|
||||
let $con3_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con3_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID in (select connection_id())`;
|
||||
|
||||
connection default;
|
||||
@ -49,6 +49,6 @@ prepare stmt_dump_events from
|
||||
where thread_id=? order by event_id;";
|
||||
|
||||
prepare stmt_dump_thread from
|
||||
"select name from performance_schema.PROCESSLIST where thread_id=? ;";
|
||||
"select name from performance_schema.THREADS where thread_id=? ;";
|
||||
--enable_query_log
|
||||
|
||||
|
@ -29,20 +29,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
--enable_result_log
|
||||
|
||||
# This has a stable output, printing the result:
|
||||
|
@ -4,7 +4,7 @@ update performance_schema.SETUP_INSTRUMENTS set enabled = 'NO';
|
||||
update performance_schema.SETUP_CONSUMERS set enabled = 'NO';
|
||||
truncate table performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
truncate table performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
update performance_schema.SETUP_CONSUMERS set enabled = 'YES';
|
||||
@ -49,14 +49,14 @@ OR @dump_all;
|
||||
EVENT_NAME SUM_NUMBER_OF_BYTES_WRITE SUM(i.SUM_NUMBER_OF_BYTES_WRITE)
|
||||
"Verifying waits aggregate consistency (instance)"
|
||||
SELECT EVENT_NAME, e.SUM_TIMER_WAIT, SUM(i.SUM_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE AS i USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
HAVING (e.SUM_TIMER_WAIT < SUM(i.SUM_TIMER_WAIT))
|
||||
OR @dump_all;
|
||||
EVENT_NAME SUM_TIMER_WAIT SUM(i.SUM_TIMER_WAIT)
|
||||
SELECT EVENT_NAME, e.MIN_TIMER_WAIT, MIN(i.MIN_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE AS i USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
HAVING (e.MIN_TIMER_WAIT > MIN(i.MIN_TIMER_WAIT))
|
||||
@ -64,7 +64,7 @@ AND (MIN(i.MIN_TIMER_WAIT) != 0)
|
||||
OR @dump_all;
|
||||
EVENT_NAME MIN_TIMER_WAIT MIN(i.MIN_TIMER_WAIT)
|
||||
SELECT EVENT_NAME, e.MAX_TIMER_WAIT, MAX(i.MAX_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE AS i USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
HAVING (e.MAX_TIMER_WAIT < MAX(i.MAX_TIMER_WAIT))
|
||||
@ -72,7 +72,7 @@ OR @dump_all;
|
||||
EVENT_NAME MAX_TIMER_WAIT MAX(i.MAX_TIMER_WAIT)
|
||||
"Verifying waits aggregate consistency (thread)"
|
||||
SELECT EVENT_NAME, e.SUM_TIMER_WAIT, SUM(t.SUM_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME AS t
|
||||
USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
@ -80,7 +80,7 @@ HAVING (e.SUM_TIMER_WAIT < SUM(t.SUM_TIMER_WAIT))
|
||||
OR @dump_all;
|
||||
EVENT_NAME SUM_TIMER_WAIT SUM(t.SUM_TIMER_WAIT)
|
||||
SELECT EVENT_NAME, e.MIN_TIMER_WAIT, MIN(t.MIN_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME AS t
|
||||
USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
@ -89,7 +89,7 @@ AND (MIN(t.MIN_TIMER_WAIT) != 0)
|
||||
OR @dump_all;
|
||||
EVENT_NAME MIN_TIMER_WAIT MIN(t.MIN_TIMER_WAIT)
|
||||
SELECT EVENT_NAME, e.MAX_TIMER_WAIT, MAX(t.MAX_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME AS t
|
||||
USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
|
2
mysql-test/suite/perfschema/r/bad_option_3.result
Normal file
2
mysql-test/suite/perfschema/r/bad_option_3.result
Normal file
@ -0,0 +1,2 @@
|
||||
Found: unknown option '-x'
|
||||
Found: Aborting
|
2
mysql-test/suite/perfschema/r/bad_option_4.result
Normal file
2
mysql-test/suite/perfschema/r/bad_option_4.result
Normal file
@ -0,0 +1,2 @@
|
||||
Found: Can't change dir to.*bad_option_h_param
|
||||
Found: Aborting
|
2
mysql-test/suite/perfschema/r/bad_option_5.result
Normal file
2
mysql-test/suite/perfschema/r/bad_option_5.result
Normal file
@ -0,0 +1,2 @@
|
||||
Found: unknown option '-X'
|
||||
Found: Aborting
|
@ -28,8 +28,8 @@ master-bin.000001 # Table_map # # table_id: # (performance_schema.SETUP_INSTRUME
|
||||
master-bin.000001 # Update_rows # # table_id: #
|
||||
master-bin.000001 # Update_rows # # table_id: # flags: STMT_END_F
|
||||
master-bin.000001 # Query # # COMMIT
|
||||
master-bin.000001 # Query # # use `test`; drop table if exists test.t1
|
||||
master-bin.000001 # Query # # use `test`; drop table if exists test.t2
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE IF EXISTS `t1` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE IF EXISTS `t2` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; create table test.t1 (thread_id integer)
|
||||
master-bin.000001 # Query # # use `test`; create table test.t2 (name varchar(128))
|
||||
master-bin.000001 # Query # # BEGIN
|
||||
@ -40,8 +40,8 @@ master-bin.000001 # Query # # BEGIN
|
||||
master-bin.000001 # Table_map # # table_id: # (test.t2)
|
||||
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
||||
master-bin.000001 # Query # # COMMIT
|
||||
master-bin.000001 # Query # # use `test`; drop table test.t1
|
||||
master-bin.000001 # Query # # use `test`; drop table test.t2
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
|
||||
master-bin.000001 # Query # # BEGIN
|
||||
master-bin.000001 # Table_map # # table_id: # (performance_schema.SETUP_INSTRUMENTS)
|
||||
master-bin.000001 # Update_rows # # table_id: #
|
||||
|
@ -28,8 +28,8 @@ master-bin.000001 # Table_map # # table_id: # (performance_schema.SETUP_INSTRUME
|
||||
master-bin.000001 # Update_rows # # table_id: #
|
||||
master-bin.000001 # Update_rows # # table_id: # flags: STMT_END_F
|
||||
master-bin.000001 # Query # # COMMIT
|
||||
master-bin.000001 # Query # # use `test`; drop table if exists test.t1
|
||||
master-bin.000001 # Query # # use `test`; drop table if exists test.t2
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE IF EXISTS `t1` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE IF EXISTS `t2` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; create table test.t1 (thread_id integer)
|
||||
master-bin.000001 # Query # # use `test`; create table test.t2 (name varchar(128))
|
||||
master-bin.000001 # Query # # BEGIN
|
||||
@ -40,8 +40,8 @@ master-bin.000001 # Query # # BEGIN
|
||||
master-bin.000001 # Table_map # # table_id: # (test.t2)
|
||||
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
||||
master-bin.000001 # Query # # COMMIT
|
||||
master-bin.000001 # Query # # use `test`; drop table test.t1
|
||||
master-bin.000001 # Query # # use `test`; drop table test.t2
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
|
||||
master-bin.000001 # Query # # BEGIN
|
||||
master-bin.000001 # Table_map # # table_id: # (performance_schema.SETUP_INSTRUMENTS)
|
||||
master-bin.000001 # Update_rows # # table_id: #
|
||||
|
@ -36,8 +36,8 @@ master-bin.000001 # Query # # BEGIN
|
||||
master-bin.000001 # Query # # use `test`; update performance_schema.SETUP_INSTRUMENTS set enabled='NO'
|
||||
where name like "wait/synch/rwlock/%"
|
||||
master-bin.000001 # Query # # COMMIT
|
||||
master-bin.000001 # Query # # use `test`; drop table if exists test.t1
|
||||
master-bin.000001 # Query # # use `test`; drop table if exists test.t2
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE IF EXISTS `t1` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE IF EXISTS `t2` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; create table test.t1 (thread_id integer)
|
||||
master-bin.000001 # Query # # use `test`; create table test.t2 (name varchar(128))
|
||||
master-bin.000001 # Query # # BEGIN
|
||||
@ -49,8 +49,8 @@ master-bin.000001 # Query # # use `test`; insert into test.t2
|
||||
select name from performance_schema.SETUP_INSTRUMENTS
|
||||
where name like "wait/synch/rwlock/%"
|
||||
master-bin.000001 # Query # # COMMIT
|
||||
master-bin.000001 # Query # # use `test`; drop table test.t1
|
||||
master-bin.000001 # Query # # use `test`; drop table test.t2
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */
|
||||
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
|
||||
master-bin.000001 # Query # # BEGIN
|
||||
master-bin.000001 # Query # # use `test`; update performance_schema.SETUP_INSTRUMENTS set enabled='YES'
|
||||
where name like "wait/synch/rwlock/%"
|
||||
|
@ -1,7 +0,0 @@
|
||||
alter table performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME add column foo integer;
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
ALTER TABLE performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME ADD INDEX test_index(EVENT_NAME);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME(EVENT_NAME);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
@ -0,0 +1,10 @@
|
||||
alter table performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
add column foo integer;
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
ALTER TABLE performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
ADD INDEX test_index(EVENT_NAME);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
CREATE UNIQUE INDEX test_index
|
||||
ON performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME(EVENT_NAME);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
@ -1,7 +0,0 @@
|
||||
alter table performance_schema.SETUP_OBJECTS add column foo integer;
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
truncate table performance_schema.SETUP_OBJECTS;
|
||||
ALTER TABLE performance_schema.SETUP_OBJECTS ADD INDEX test_index(OBJECT_NAME);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.SETUP_OBJECTS(OBJECT_NAME);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
@ -1,8 +1,8 @@
|
||||
alter table performance_schema.PROCESSLIST add column foo integer;
|
||||
alter table performance_schema.THREADS add column foo integer;
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
truncate table performance_schema.PROCESSLIST;
|
||||
truncate table performance_schema.THREADS;
|
||||
ERROR HY000: Invalid performance_schema usage.
|
||||
ALTER TABLE performance_schema.PROCESSLIST ADD INDEX test_index(ID);
|
||||
ALTER TABLE performance_schema.THREADS ADD INDEX test_index(ID);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.PROCESSLIST(ID);
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.THREADS(ID);
|
||||
ERROR 42000: Access denied for user 'root'@'localhost' to database 'performance_schema'
|
@ -1,28 +0,0 @@
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
where event_name like 'Wait/Synch/%' limit 1;
|
||||
EVENT_NAME COUNT_STAR SUM_TIMER_WAIT MIN_TIMER_WAIT AVG_TIMER_WAIT MAX_TIMER_WAIT
|
||||
# # # # # #
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
where event_name='FOO';
|
||||
EVENT_NAME COUNT_STAR SUM_TIMER_WAIT MIN_TIMER_WAIT AVG_TIMER_WAIT MAX_TIMER_WAIT
|
||||
insert into performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
set event_name='FOO', count_star=1, sum_timer_wait=2, min_timer_wait=3,
|
||||
avg_timer_wait=4, max_timer_wait=5;
|
||||
ERROR 42000: INSERT command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
set count_star=12;
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
set count_star=12 where event_name like "FOO";
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
where count_star=1;
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME READ;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
UNLOCK TABLES;
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME WRITE;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
UNLOCK TABLES;
|
@ -0,0 +1,28 @@
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
where event_name like 'Wait/Synch/%' limit 1;
|
||||
EVENT_NAME COUNT_STAR SUM_TIMER_WAIT MIN_TIMER_WAIT AVG_TIMER_WAIT MAX_TIMER_WAIT
|
||||
# # # # # #
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
where event_name='FOO';
|
||||
EVENT_NAME COUNT_STAR SUM_TIMER_WAIT MIN_TIMER_WAIT AVG_TIMER_WAIT MAX_TIMER_WAIT
|
||||
insert into performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
set event_name='FOO', count_star=1, sum_timer_wait=2, min_timer_wait=3,
|
||||
avg_timer_wait=4, max_timer_wait=5;
|
||||
ERROR 42000: INSERT command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
set count_star=12;
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
set count_star=12 where event_name like "FOO";
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
where count_star=1;
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME READ;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
UNLOCK TABLES;
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME WRITE;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
UNLOCK TABLES;
|
@ -40,12 +40,12 @@ wait/synch/cond/sql/COND_flush_thread_cache YES YES
|
||||
wait/synch/cond/sql/COND_global_read_lock YES YES
|
||||
wait/synch/cond/sql/COND_manager YES YES
|
||||
wait/synch/cond/sql/COND_queue_state YES YES
|
||||
wait/synch/cond/sql/COND_refresh YES YES
|
||||
wait/synch/cond/sql/COND_rpl_status YES YES
|
||||
wait/synch/cond/sql/COND_server_started YES YES
|
||||
wait/synch/cond/sql/COND_thread_cache YES YES
|
||||
wait/synch/cond/sql/COND_thread_count YES YES
|
||||
wait/synch/cond/sql/Delayed_insert::cond YES YES
|
||||
wait/synch/cond/sql/Delayed_insert::cond_client YES YES
|
||||
select * from performance_schema.SETUP_INSTRUMENTS
|
||||
where name='Wait';
|
||||
select * from performance_schema.SETUP_INSTRUMENTS
|
||||
|
@ -1,35 +0,0 @@
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
OBJECT_TYPE OBJECT_SCHEMA OBJECT_NAME ENABLED TIMED AGGREGATED
|
||||
select * from performance_schema.SETUP_OBJECTS
|
||||
where object_type = 'TABLE';
|
||||
OBJECT_TYPE OBJECT_SCHEMA OBJECT_NAME ENABLED TIMED AGGREGATED
|
||||
select * from performance_schema.SETUP_OBJECTS
|
||||
where enabled='YES';
|
||||
OBJECT_TYPE OBJECT_SCHEMA OBJECT_NAME ENABLED TIMED AGGREGATED
|
||||
insert into performance_schema.SETUP_OBJECTS
|
||||
set object_type='TABLE', object_schema='FOO', object_name='BAR',
|
||||
enabled='YES', timed='YES', aggregated='YES';
|
||||
ERROR HY000: Table storage engine for 'SETUP_OBJECTS' doesn't have this option
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set object_type='TABLE';
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set object_schema='ILLEGAL';
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set object_name='ILLEGAL';
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set enabled='NO';
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set timed='NO';
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set aggregated='NO';
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
OBJECT_TYPE OBJECT_SCHEMA OBJECT_NAME ENABLED TIMED AGGREGATED
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set enabled='YES', timed='YES', aggregated='YES';
|
||||
delete from performance_schema.SETUP_OBJECTS
|
||||
where object_type = 'TABLE';
|
||||
delete from performance_schema.SETUP_OBJECTS;
|
||||
LOCK TABLES performance_schema.SETUP_OBJECTS READ;
|
||||
UNLOCK TABLES;
|
||||
LOCK TABLES performance_schema.SETUP_OBJECTS WRITE;
|
||||
UNLOCK TABLES;
|
@ -1,27 +1,27 @@
|
||||
select * from performance_schema.PROCESSLIST
|
||||
select * from performance_schema.THREADS
|
||||
where name like 'Thread/%' limit 1;
|
||||
THREAD_ID ID NAME
|
||||
# # #
|
||||
select * from performance_schema.PROCESSLIST
|
||||
select * from performance_schema.THREADS
|
||||
where name='FOO';
|
||||
THREAD_ID ID NAME
|
||||
insert into performance_schema.PROCESSLIST
|
||||
insert into performance_schema.THREADS
|
||||
set name='FOO', thread_id=1, id=2;
|
||||
ERROR 42000: INSERT command denied to user 'root'@'localhost' for table 'PROCESSLIST'
|
||||
update performance_schema.PROCESSLIST
|
||||
ERROR 42000: INSERT command denied to user 'root'@'localhost' for table 'THREADS'
|
||||
update performance_schema.THREADS
|
||||
set thread_id=12;
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'PROCESSLIST'
|
||||
update performance_schema.PROCESSLIST
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'THREADS'
|
||||
update performance_schema.THREADS
|
||||
set thread_id=12 where name like "FOO";
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'PROCESSLIST'
|
||||
delete from performance_schema.PROCESSLIST
|
||||
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table 'THREADS'
|
||||
delete from performance_schema.THREADS
|
||||
where id=1;
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'PROCESSLIST'
|
||||
delete from performance_schema.PROCESSLIST;
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'PROCESSLIST'
|
||||
LOCK TABLES performance_schema.PROCESSLIST READ;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'PROCESSLIST'
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'THREADS'
|
||||
delete from performance_schema.THREADS;
|
||||
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table 'THREADS'
|
||||
LOCK TABLES performance_schema.THREADS READ;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'THREADS'
|
||||
UNLOCK TABLES;
|
||||
LOCK TABLES performance_schema.PROCESSLIST WRITE;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'PROCESSLIST'
|
||||
LOCK TABLES performance_schema.THREADS WRITE;
|
||||
ERROR 42000: SELECT,LOCK TABL command denied to user 'root'@'localhost' for table 'THREADS'
|
||||
UNLOCK TABLES;
|
@ -90,27 +90,27 @@ SUM(SUM_NUMBER_OF_BYTES_WRITE) AS sum_num_bytes_write
|
||||
FROM performance_schema.FILE_SUMMARY_BY_INSTANCE
|
||||
WHERE FILE_NAME LIKE CONCAT('%', @@tmpdir, '%') ORDER BY NULL;
|
||||
SELECT EVENT_NAME, COUNT_STAR, AVG_TIMER_WAIT, SUM_TIMER_WAIT
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
WHERE COUNT_STAR > 0
|
||||
ORDER BY SUM_TIMER_WAIT DESC
|
||||
LIMIT 10;
|
||||
SELECT i.user, SUM(TIMER_WAIT) SUM_WAIT
|
||||
# ((TIME_TO_SEC(TIMEDIFF(NOW(), i.startup_time)) * 1000) / SUM(TIMER_WAIT)) * 100 WAIT_PERCENTAGE
|
||||
FROM performance_schema.EVENTS_WAITS_HISTORY_LONG h
|
||||
INNER JOIN performance_schema.PROCESSLIST p USING (THREAD_ID)
|
||||
INNER JOIN performance_schema.THREADS p USING (THREAD_ID)
|
||||
LEFT JOIN information_schema.PROCESSLIST i USING (ID)
|
||||
GROUP BY i.user
|
||||
ORDER BY SUM_WAIT DESC
|
||||
LIMIT 20;
|
||||
SELECT h.EVENT_NAME, SUM(h.TIMER_WAIT) TOTAL_WAIT
|
||||
FROM performance_schema.EVENTS_WAITS_HISTORY_LONG h
|
||||
INNER JOIN performance_schema.PROCESSLIST p USING (THREAD_ID)
|
||||
INNER JOIN performance_schema.THREADS p USING (THREAD_ID)
|
||||
WHERE p.ID = 1
|
||||
GROUP BY h.EVENT_NAME
|
||||
HAVING TOTAL_WAIT > 0;
|
||||
SELECT i.user, h.operation, SUM(NUMBER_OF_BYTES) bytes
|
||||
FROM performance_schema.EVENTS_WAITS_HISTORY_LONG h
|
||||
INNER JOIN performance_schema.PROCESSLIST p USING (THREAD_ID)
|
||||
INNER JOIN performance_schema.THREADS p USING (THREAD_ID)
|
||||
LEFT JOIN information_schema.PROCESSLIST i USING (ID)
|
||||
GROUP BY i.user, h.operation
|
||||
HAVING BYTES > 0
|
||||
|
@ -6,20 +6,19 @@ performance_schema COND_INSTANCES def
|
||||
performance_schema EVENTS_WAITS_CURRENT def
|
||||
performance_schema EVENTS_WAITS_HISTORY def
|
||||
performance_schema EVENTS_WAITS_HISTORY_LONG def
|
||||
performance_schema EVENTS_WAITS_SUMMARY_BY_EVENT_NAME def
|
||||
performance_schema EVENTS_WAITS_SUMMARY_BY_INSTANCE def
|
||||
performance_schema EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME def
|
||||
performance_schema EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME def
|
||||
performance_schema FILE_INSTANCES def
|
||||
performance_schema FILE_SUMMARY_BY_EVENT_NAME def
|
||||
performance_schema FILE_SUMMARY_BY_INSTANCE def
|
||||
performance_schema MUTEX_INSTANCES def
|
||||
performance_schema PERFORMANCE_TIMERS def
|
||||
performance_schema PROCESSLIST def
|
||||
performance_schema RWLOCK_INSTANCES def
|
||||
performance_schema SETUP_CONSUMERS def
|
||||
performance_schema SETUP_INSTRUMENTS def
|
||||
performance_schema SETUP_OBJECTS def
|
||||
performance_schema SETUP_TIMERS def
|
||||
performance_schema THREADS def
|
||||
select upper(TABLE_NAME), TABLE_TYPE, ENGINE
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -28,20 +27,19 @@ COND_INSTANCES BASE TABLE PERFORMANCE_SCHEMA
|
||||
EVENTS_WAITS_CURRENT BASE TABLE PERFORMANCE_SCHEMA
|
||||
EVENTS_WAITS_HISTORY BASE TABLE PERFORMANCE_SCHEMA
|
||||
EVENTS_WAITS_HISTORY_LONG BASE TABLE PERFORMANCE_SCHEMA
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME BASE TABLE PERFORMANCE_SCHEMA
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE BASE TABLE PERFORMANCE_SCHEMA
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME BASE TABLE PERFORMANCE_SCHEMA
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME BASE TABLE PERFORMANCE_SCHEMA
|
||||
FILE_INSTANCES BASE TABLE PERFORMANCE_SCHEMA
|
||||
FILE_SUMMARY_BY_EVENT_NAME BASE TABLE PERFORMANCE_SCHEMA
|
||||
FILE_SUMMARY_BY_INSTANCE BASE TABLE PERFORMANCE_SCHEMA
|
||||
MUTEX_INSTANCES BASE TABLE PERFORMANCE_SCHEMA
|
||||
PERFORMANCE_TIMERS BASE TABLE PERFORMANCE_SCHEMA
|
||||
PROCESSLIST BASE TABLE PERFORMANCE_SCHEMA
|
||||
RWLOCK_INSTANCES BASE TABLE PERFORMANCE_SCHEMA
|
||||
SETUP_CONSUMERS BASE TABLE PERFORMANCE_SCHEMA
|
||||
SETUP_INSTRUMENTS BASE TABLE PERFORMANCE_SCHEMA
|
||||
SETUP_OBJECTS BASE TABLE PERFORMANCE_SCHEMA
|
||||
SETUP_TIMERS BASE TABLE PERFORMANCE_SCHEMA
|
||||
THREADS BASE TABLE PERFORMANCE_SCHEMA
|
||||
select upper(TABLE_NAME), VERSION, ROW_FORMAT
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -50,20 +48,19 @@ COND_INSTANCES 10 Dynamic
|
||||
EVENTS_WAITS_CURRENT 10 Dynamic
|
||||
EVENTS_WAITS_HISTORY 10 Dynamic
|
||||
EVENTS_WAITS_HISTORY_LONG 10 Dynamic
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME 10 Dynamic
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE 10 Dynamic
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME 10 Dynamic
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME 10 Dynamic
|
||||
FILE_INSTANCES 10 Dynamic
|
||||
FILE_SUMMARY_BY_EVENT_NAME 10 Dynamic
|
||||
FILE_SUMMARY_BY_INSTANCE 10 Dynamic
|
||||
MUTEX_INSTANCES 10 Dynamic
|
||||
PERFORMANCE_TIMERS 10 Fixed
|
||||
PROCESSLIST 10 Dynamic
|
||||
RWLOCK_INSTANCES 10 Dynamic
|
||||
SETUP_CONSUMERS 10 Dynamic
|
||||
SETUP_INSTRUMENTS 10 Dynamic
|
||||
SETUP_OBJECTS 10 Dynamic
|
||||
SETUP_TIMERS 10 Dynamic
|
||||
THREADS 10 Dynamic
|
||||
select upper(TABLE_NAME), TABLE_ROWS, AVG_ROW_LENGTH
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -72,20 +69,19 @@ COND_INSTANCES 1000 0
|
||||
EVENTS_WAITS_CURRENT 1000 0
|
||||
EVENTS_WAITS_HISTORY 1000 0
|
||||
EVENTS_WAITS_HISTORY_LONG 10000 0
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME 1000 0
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE 1000 0
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME 1000 0
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME 1000 0
|
||||
FILE_INSTANCES 1000 0
|
||||
FILE_SUMMARY_BY_EVENT_NAME 1000 0
|
||||
FILE_SUMMARY_BY_INSTANCE 1000 0
|
||||
MUTEX_INSTANCES 1000 0
|
||||
PERFORMANCE_TIMERS 5 0
|
||||
PROCESSLIST 1000 0
|
||||
RWLOCK_INSTANCES 1000 0
|
||||
SETUP_CONSUMERS 8 0
|
||||
SETUP_INSTRUMENTS 1000 0
|
||||
SETUP_OBJECTS 1000 0
|
||||
SETUP_TIMERS 1 0
|
||||
THREADS 1000 0
|
||||
select upper(TABLE_NAME), DATA_LENGTH, MAX_DATA_LENGTH
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -94,20 +90,19 @@ COND_INSTANCES 0 0
|
||||
EVENTS_WAITS_CURRENT 0 0
|
||||
EVENTS_WAITS_HISTORY 0 0
|
||||
EVENTS_WAITS_HISTORY_LONG 0 0
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME 0 0
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE 0 0
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME 0 0
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME 0 0
|
||||
FILE_INSTANCES 0 0
|
||||
FILE_SUMMARY_BY_EVENT_NAME 0 0
|
||||
FILE_SUMMARY_BY_INSTANCE 0 0
|
||||
MUTEX_INSTANCES 0 0
|
||||
PERFORMANCE_TIMERS 0 0
|
||||
PROCESSLIST 0 0
|
||||
RWLOCK_INSTANCES 0 0
|
||||
SETUP_CONSUMERS 0 0
|
||||
SETUP_INSTRUMENTS 0 0
|
||||
SETUP_OBJECTS 0 0
|
||||
SETUP_TIMERS 0 0
|
||||
THREADS 0 0
|
||||
select upper(TABLE_NAME), INDEX_LENGTH, DATA_FREE, AUTO_INCREMENT
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -116,20 +111,19 @@ COND_INSTANCES 0 0 NULL
|
||||
EVENTS_WAITS_CURRENT 0 0 NULL
|
||||
EVENTS_WAITS_HISTORY 0 0 NULL
|
||||
EVENTS_WAITS_HISTORY_LONG 0 0 NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME 0 0 NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE 0 0 NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME 0 0 NULL
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME 0 0 NULL
|
||||
FILE_INSTANCES 0 0 NULL
|
||||
FILE_SUMMARY_BY_EVENT_NAME 0 0 NULL
|
||||
FILE_SUMMARY_BY_INSTANCE 0 0 NULL
|
||||
MUTEX_INSTANCES 0 0 NULL
|
||||
PERFORMANCE_TIMERS 0 0 NULL
|
||||
PROCESSLIST 0 0 NULL
|
||||
RWLOCK_INSTANCES 0 0 NULL
|
||||
SETUP_CONSUMERS 0 0 NULL
|
||||
SETUP_INSTRUMENTS 0 0 NULL
|
||||
SETUP_OBJECTS 0 0 NULL
|
||||
SETUP_TIMERS 0 0 NULL
|
||||
THREADS 0 0 NULL
|
||||
select upper(TABLE_NAME), CREATE_TIME, UPDATE_TIME, CHECK_TIME
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -138,20 +132,19 @@ COND_INSTANCES NULL NULL NULL
|
||||
EVENTS_WAITS_CURRENT NULL NULL NULL
|
||||
EVENTS_WAITS_HISTORY NULL NULL NULL
|
||||
EVENTS_WAITS_HISTORY_LONG NULL NULL NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME NULL NULL NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE NULL NULL NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME NULL NULL NULL
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME NULL NULL NULL
|
||||
FILE_INSTANCES NULL NULL NULL
|
||||
FILE_SUMMARY_BY_EVENT_NAME NULL NULL NULL
|
||||
FILE_SUMMARY_BY_INSTANCE NULL NULL NULL
|
||||
MUTEX_INSTANCES NULL NULL NULL
|
||||
PERFORMANCE_TIMERS NULL NULL NULL
|
||||
PROCESSLIST NULL NULL NULL
|
||||
RWLOCK_INSTANCES NULL NULL NULL
|
||||
SETUP_CONSUMERS NULL NULL NULL
|
||||
SETUP_INSTRUMENTS NULL NULL NULL
|
||||
SETUP_OBJECTS NULL NULL NULL
|
||||
SETUP_TIMERS NULL NULL NULL
|
||||
THREADS NULL NULL NULL
|
||||
select upper(TABLE_NAME), TABLE_COLLATION, CHECKSUM
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -160,20 +153,19 @@ COND_INSTANCES utf8_general_ci NULL
|
||||
EVENTS_WAITS_CURRENT utf8_general_ci NULL
|
||||
EVENTS_WAITS_HISTORY utf8_general_ci NULL
|
||||
EVENTS_WAITS_HISTORY_LONG utf8_general_ci NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME utf8_general_ci NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE utf8_general_ci NULL
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME utf8_general_ci NULL
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME utf8_general_ci NULL
|
||||
FILE_INSTANCES utf8_general_ci NULL
|
||||
FILE_SUMMARY_BY_EVENT_NAME utf8_general_ci NULL
|
||||
FILE_SUMMARY_BY_INSTANCE utf8_general_ci NULL
|
||||
MUTEX_INSTANCES utf8_general_ci NULL
|
||||
PERFORMANCE_TIMERS utf8_general_ci NULL
|
||||
PROCESSLIST utf8_general_ci NULL
|
||||
RWLOCK_INSTANCES utf8_general_ci NULL
|
||||
SETUP_CONSUMERS utf8_general_ci NULL
|
||||
SETUP_INSTRUMENTS utf8_general_ci NULL
|
||||
SETUP_OBJECTS utf8_general_ci NULL
|
||||
SETUP_TIMERS utf8_general_ci NULL
|
||||
THREADS utf8_general_ci NULL
|
||||
select upper(TABLE_NAME), TABLE_COMMENT
|
||||
from information_schema.tables
|
||||
where TABLE_SCHEMA='performance_schema';
|
||||
@ -182,17 +174,16 @@ COND_INSTANCES
|
||||
EVENTS_WAITS_CURRENT
|
||||
EVENTS_WAITS_HISTORY
|
||||
EVENTS_WAITS_HISTORY_LONG
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
FILE_INSTANCES
|
||||
FILE_SUMMARY_BY_EVENT_NAME
|
||||
FILE_SUMMARY_BY_INSTANCE
|
||||
MUTEX_INSTANCES
|
||||
PERFORMANCE_TIMERS
|
||||
PROCESSLIST
|
||||
RWLOCK_INSTANCES
|
||||
SETUP_CONSUMERS
|
||||
SETUP_INSTRUMENTS
|
||||
SETUP_OBJECTS
|
||||
SETUP_TIMERS
|
||||
THREADS
|
||||
|
@ -1,6 +1,6 @@
|
||||
SELECT EVENT_ID FROM performance_schema.EVENTS_WAITS_CURRENT
|
||||
WHERE THREAD_ID IN
|
||||
(SELECT THREAD_ID FROM performance_schema.PROCESSLIST)
|
||||
(SELECT THREAD_ID FROM performance_schema.THREADS)
|
||||
AND EVENT_NAME IN
|
||||
(SELECT NAME FROM performance_schema.SETUP_INSTRUMENTS
|
||||
WHERE NAME LIKE "wait/synch/%")
|
||||
|
@ -17,11 +17,11 @@ show variables like "performance_schema_max_thread%";
|
||||
Variable_name Value
|
||||
performance_schema_max_thread_classes 50
|
||||
performance_schema_max_thread_instances 10
|
||||
select count(*) from performance_schema.PROCESSLIST
|
||||
select count(*) from performance_schema.THREADS
|
||||
where name like "thread/sql/main";
|
||||
count(*)
|
||||
1
|
||||
select count(*) from performance_schema.PROCESSLIST
|
||||
select count(*) from performance_schema.THREADS
|
||||
where name like "thread/sql/OneConnection";
|
||||
count(*)
|
||||
0
|
||||
|
@ -12,21 +12,20 @@ ERROR 1050 (42S01) at line 183: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 213: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 227: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 241: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 282: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 262: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 283: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 320: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 339: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 376: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 394: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 411: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 429: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 462: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 498: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1644 (HY000) at line 1142: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 412: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 428: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 461: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 478: Table 'THREADS' already exists
|
||||
ERROR 1644 (HY000) at line 1122: Unexpected content found in the performance_schema database.
|
||||
FATAL ERROR: Upgrade failed
|
||||
show tables like "user_table";
|
||||
Tables_in_performance_schema (user_table)
|
||||
@ -43,21 +42,20 @@ ERROR 1050 (42S01) at line 183: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 213: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 227: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 241: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 282: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 262: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 283: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 320: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 339: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 376: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 394: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 411: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 429: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 462: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 498: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1644 (HY000) at line 1142: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 412: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 428: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 461: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 478: Table 'THREADS' already exists
|
||||
ERROR 1644 (HY000) at line 1122: Unexpected content found in the performance_schema database.
|
||||
FATAL ERROR: Upgrade failed
|
||||
show tables like "user_view";
|
||||
Tables_in_performance_schema (user_view)
|
||||
@ -72,21 +70,20 @@ ERROR 1050 (42S01) at line 183: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 213: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 227: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 241: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 282: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 262: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 283: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 320: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 339: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 376: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 394: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 411: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 429: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 462: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 498: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1644 (HY000) at line 1142: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 412: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 428: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 461: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 478: Table 'THREADS' already exists
|
||||
ERROR 1644 (HY000) at line 1122: Unexpected content found in the performance_schema database.
|
||||
FATAL ERROR: Upgrade failed
|
||||
select name from mysql.proc where db='performance_schema';
|
||||
name
|
||||
@ -101,21 +98,20 @@ ERROR 1050 (42S01) at line 183: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 213: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 227: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 241: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 282: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 262: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 283: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 320: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 339: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 376: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 394: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 411: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 429: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 462: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 498: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1644 (HY000) at line 1142: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 412: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 428: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 461: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 478: Table 'THREADS' already exists
|
||||
ERROR 1644 (HY000) at line 1122: Unexpected content found in the performance_schema database.
|
||||
FATAL ERROR: Upgrade failed
|
||||
select name from mysql.proc where db='performance_schema';
|
||||
name
|
||||
@ -130,21 +126,20 @@ ERROR 1050 (42S01) at line 183: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 213: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 227: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 241: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 282: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 262: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 283: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 303: Table 'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 320: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 339: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 376: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 394: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 411: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 429: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 462: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 498: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1644 (HY000) at line 1142: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 412: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 428: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 445: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 461: Table 'SETUP_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 478: Table 'THREADS' already exists
|
||||
ERROR 1644 (HY000) at line 1122: Unexpected content found in the performance_schema database.
|
||||
FATAL ERROR: Upgrade failed
|
||||
select name from mysql.event where db='performance_schema';
|
||||
name
|
||||
|
@ -12,20 +12,19 @@ COND_INSTANCES
|
||||
EVENTS_WAITS_CURRENT
|
||||
EVENTS_WAITS_HISTORY
|
||||
EVENTS_WAITS_HISTORY_LONG
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE
|
||||
EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
FILE_INSTANCES
|
||||
FILE_SUMMARY_BY_EVENT_NAME
|
||||
FILE_SUMMARY_BY_INSTANCE
|
||||
MUTEX_INSTANCES
|
||||
PERFORMANCE_TIMERS
|
||||
PROCESSLIST
|
||||
RWLOCK_INSTANCES
|
||||
SETUP_CONSUMERS
|
||||
SETUP_INSTRUMENTS
|
||||
SETUP_OBJECTS
|
||||
SETUP_TIMERS
|
||||
THREADS
|
||||
show create table COND_INSTANCES;
|
||||
Table Create Table
|
||||
COND_INSTANCES CREATE TABLE `COND_INSTANCES` (
|
||||
@ -92,16 +91,6 @@ EVENTS_WAITS_HISTORY_LONG CREATE TABLE `EVENTS_WAITS_HISTORY_LONG` (
|
||||
`NUMBER_OF_BYTES` bigint(20) unsigned DEFAULT NULL,
|
||||
`FLAGS` int(10) unsigned DEFAULT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
Table Create Table
|
||||
EVENTS_WAITS_SUMMARY_BY_EVENT_NAME CREATE TABLE `EVENTS_WAITS_SUMMARY_BY_EVENT_NAME` (
|
||||
`EVENT_NAME` varchar(128) NOT NULL,
|
||||
`COUNT_STAR` bigint(20) unsigned NOT NULL,
|
||||
`SUM_TIMER_WAIT` bigint(20) unsigned NOT NULL,
|
||||
`MIN_TIMER_WAIT` bigint(20) unsigned NOT NULL,
|
||||
`AVG_TIMER_WAIT` bigint(20) unsigned NOT NULL,
|
||||
`MAX_TIMER_WAIT` bigint(20) unsigned NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
Table Create Table
|
||||
EVENTS_WAITS_SUMMARY_BY_INSTANCE CREATE TABLE `EVENTS_WAITS_SUMMARY_BY_INSTANCE` (
|
||||
@ -124,6 +113,16 @@ EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME CREATE TABLE `EVENTS_WAITS_SUMMARY_
|
||||
`AVG_TIMER_WAIT` bigint(20) unsigned NOT NULL,
|
||||
`MAX_TIMER_WAIT` bigint(20) unsigned NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
Table Create Table
|
||||
EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME CREATE TABLE `EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME` (
|
||||
`EVENT_NAME` varchar(128) NOT NULL,
|
||||
`COUNT_STAR` bigint(20) unsigned NOT NULL,
|
||||
`SUM_TIMER_WAIT` bigint(20) unsigned NOT NULL,
|
||||
`MIN_TIMER_WAIT` bigint(20) unsigned NOT NULL,
|
||||
`AVG_TIMER_WAIT` bigint(20) unsigned NOT NULL,
|
||||
`MAX_TIMER_WAIT` bigint(20) unsigned NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table FILE_INSTANCES;
|
||||
Table Create Table
|
||||
FILE_INSTANCES CREATE TABLE `FILE_INSTANCES` (
|
||||
@ -165,13 +164,6 @@ PERFORMANCE_TIMERS CREATE TABLE `PERFORMANCE_TIMERS` (
|
||||
`TIMER_RESOLUTION` bigint(20) DEFAULT NULL,
|
||||
`TIMER_OVERHEAD` bigint(20) DEFAULT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table PROCESSLIST;
|
||||
Table Create Table
|
||||
PROCESSLIST CREATE TABLE `PROCESSLIST` (
|
||||
`THREAD_ID` int(11) NOT NULL,
|
||||
`ID` int(11) NOT NULL,
|
||||
`NAME` varchar(64) NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table RWLOCK_INSTANCES;
|
||||
Table Create Table
|
||||
RWLOCK_INSTANCES CREATE TABLE `RWLOCK_INSTANCES` (
|
||||
@ -193,19 +185,16 @@ SETUP_INSTRUMENTS CREATE TABLE `SETUP_INSTRUMENTS` (
|
||||
`ENABLED` enum('YES','NO') NOT NULL,
|
||||
`TIMED` enum('YES','NO') NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table SETUP_OBJECTS;
|
||||
Table Create Table
|
||||
SETUP_OBJECTS CREATE TABLE `SETUP_OBJECTS` (
|
||||
`OBJECT_TYPE` varchar(64) DEFAULT NULL,
|
||||
`OBJECT_SCHEMA` varchar(64) DEFAULT NULL,
|
||||
`OBJECT_NAME` varchar(64) DEFAULT NULL,
|
||||
`ENABLED` enum('YES','NO') NOT NULL,
|
||||
`TIMED` enum('YES','NO') NOT NULL,
|
||||
`AGGREGATED` enum('YES','NO') NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table SETUP_TIMERS;
|
||||
Table Create Table
|
||||
SETUP_TIMERS CREATE TABLE `SETUP_TIMERS` (
|
||||
`NAME` varchar(64) NOT NULL,
|
||||
`TIMER_NAME` enum('CYCLE','NANOSECOND','MICROSECOND','MILLISECOND','TICK') NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
show create table THREADS;
|
||||
Table Create Table
|
||||
THREADS CREATE TABLE `THREADS` (
|
||||
`THREAD_ID` int(11) NOT NULL,
|
||||
`ID` int(11) NOT NULL,
|
||||
`NAME` varchar(64) NOT NULL
|
||||
) ENGINE=PERFORMANCE_SCHEMA DEFAULT CHARSET=utf8
|
||||
|
@ -13,7 +13,7 @@ OPERATION TOTAL
|
||||
chsize [NUM_BYTES]
|
||||
SELECT EVENT_ID FROM performance_schema.EVENTS_WAITS_CURRENT
|
||||
WHERE THREAD_ID IN
|
||||
(SELECT THREAD_ID FROM performance_schema.PROCESSLIST)
|
||||
(SELECT THREAD_ID FROM performance_schema.THREADS)
|
||||
AND EVENT_NAME IN
|
||||
(SELECT NAME FROM performance_schema.SETUP_INSTRUMENTS
|
||||
WHERE NAME LIKE "wait/synch/%")
|
||||
@ -86,7 +86,7 @@ DROP TRIGGER t_ps_trigger;
|
||||
DROP PROCEDURE IF EXISTS t_ps_proc;
|
||||
CREATE PROCEDURE t_ps_proc(IN tid INT, OUT pid INT)
|
||||
BEGIN
|
||||
SELECT id FROM performance_schema.PROCESSLIST
|
||||
SELECT id FROM performance_schema.THREADS
|
||||
WHERE THREAD_ID = tid INTO pid;
|
||||
END;
|
||||
|
|
||||
@ -94,7 +94,7 @@ CALL t_ps_proc(0, @p_id);
|
||||
DROP FUNCTION IF EXISTS t_ps_proc;
|
||||
CREATE FUNCTION t_ps_func(tid INT) RETURNS int
|
||||
BEGIN
|
||||
return (SELECT id FROM performance_schema.PROCESSLIST
|
||||
return (SELECT id FROM performance_schema.THREADS
|
||||
WHERE THREAD_ID = tid);
|
||||
END;
|
||||
|
|
||||
|
@ -182,7 +182,7 @@ count(name)
|
||||
select count(name) from COND_INSTANCES
|
||||
where name like "wait/synch/cond/sql/COND_refresh";
|
||||
count(name)
|
||||
1
|
||||
0
|
||||
select count(name) from COND_INSTANCES
|
||||
where name like "wait/synch/cond/sql/COND_thread_count";
|
||||
count(name)
|
||||
|
27
mysql-test/suite/perfschema/r/short_option_1.result
Normal file
27
mysql-test/suite/perfschema/r/short_option_1.result
Normal file
@ -0,0 +1,27 @@
|
||||
select 'Ok, the server started' as result;
|
||||
result
|
||||
Ok, the server started
|
||||
select @@SQL_MODE;
|
||||
@@SQL_MODE
|
||||
REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,ANSI
|
||||
show variables like 'sql_mode';
|
||||
Variable_name Value
|
||||
sql_mode REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,ANSI
|
||||
select @@character_set_server;
|
||||
@@character_set_server
|
||||
utf8
|
||||
show variables like 'character_set_system';
|
||||
Variable_name Value
|
||||
character_set_system utf8
|
||||
show variables like 'log';
|
||||
Variable_name Value
|
||||
log ON
|
||||
show variables like 'general_log';
|
||||
Variable_name Value
|
||||
general_log ON
|
||||
show variables like 'new';
|
||||
Variable_name Value
|
||||
new ON
|
||||
show variables like 'log_warnings';
|
||||
Variable_name Value
|
||||
log_warnings 3
|
9
mysql-test/suite/perfschema/r/short_option_2.result
Normal file
9
mysql-test/suite/perfschema/r/short_option_2.result
Normal file
@ -0,0 +1,9 @@
|
||||
select 'Ok, the server started' as result;
|
||||
result
|
||||
Ok, the server started
|
||||
select @@SQL_MODE;
|
||||
@@SQL_MODE
|
||||
REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,ANSI
|
||||
select @@log_warnings;
|
||||
@@log_warnings
|
||||
5
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 0
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 0
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 0
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -47,8 +46,8 @@ 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 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 0
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,8 +45,8 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 0
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
@ -57,7 +56,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 20
|
||||
performance_schema_max_rwlock_classes 30
|
||||
select count(*) > 0 from performance_schema.SETUP_INSTRUMENTS
|
||||
where name like "wait/synch/rwlock/%";
|
||||
count(*) > 0
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 0
|
||||
@ -66,7 +65,7 @@ select variable_value > 0 from information_schema.global_status
|
||||
where variable_name like 'PERFORMANCE_SCHEMA_THREAD_CLASSES_LOST';
|
||||
variable_value > 0
|
||||
1
|
||||
select count(*) from performance_schema.PROCESSLIST;
|
||||
select count(*) from performance_schema.THREADS;
|
||||
count(*)
|
||||
0
|
||||
show status like "performance_schema_thread_instances_lost";
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
@ -64,7 +63,7 @@ Performance_schema_thread_classes_lost 0
|
||||
show variables like "performance_schema_max_thread_instances";
|
||||
Variable_name Value
|
||||
performance_schema_max_thread_instances 0
|
||||
select count(*) from performance_schema.PROCESSLIST;
|
||||
select count(*) from performance_schema.THREADS;
|
||||
count(*)
|
||||
0
|
||||
select variable_value > 0 from information_schema.global_status
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema OFF
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -21,20 +21,19 @@ select * from performance_schema.COND_INSTANCES;
|
||||
select * from performance_schema.EVENTS_WAITS_CURRENT;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY;
|
||||
select * from performance_schema.EVENTS_WAITS_HISTORY_LONG;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_INSTANCES;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
select * from performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
select * from performance_schema.MUTEX_INSTANCES;
|
||||
select * from performance_schema.PERFORMANCE_TIMERS;
|
||||
select * from performance_schema.PROCESSLIST;
|
||||
select * from performance_schema.RWLOCK_INSTANCES;
|
||||
select * from performance_schema.SETUP_CONSUMERS;
|
||||
select * from performance_schema.SETUP_INSTRUMENTS;
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
select * from performance_schema.SETUP_TIMERS;
|
||||
select * from performance_schema.THREADS;
|
||||
show variables like "performance_schema%";
|
||||
Variable_name Value
|
||||
performance_schema ON
|
||||
@ -46,9 +45,9 @@ performance_schema_max_file_classes 50
|
||||
performance_schema_max_file_handles 32768
|
||||
performance_schema_max_file_instances 10000
|
||||
performance_schema_max_mutex_classes 200
|
||||
performance_schema_max_mutex_instances 1000
|
||||
performance_schema_max_rwlock_classes 20
|
||||
performance_schema_max_rwlock_instances 1000
|
||||
performance_schema_max_mutex_instances 1000000
|
||||
performance_schema_max_rwlock_classes 30
|
||||
performance_schema_max_rwlock_instances 1000000
|
||||
performance_schema_max_table_handles 100000
|
||||
performance_schema_max_table_instances 50000
|
||||
performance_schema_max_thread_classes 50
|
||||
|
@ -31,7 +31,7 @@ update performance_schema.SETUP_CONSUMERS set enabled = 'NO';
|
||||
# Cleanup statistics
|
||||
truncate table performance_schema.FILE_SUMMARY_BY_EVENT_NAME;
|
||||
truncate table performance_schema.FILE_SUMMARY_BY_INSTANCE;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
|
||||
@ -66,9 +66,9 @@ set @dump_all=FALSE;
|
||||
# because doing so removes a row in FILE_SUMMARY_BY_INSTANCE.
|
||||
|
||||
# Likewise:
|
||||
# - COUNT/SUM/MAX(EVENTS_WAITS_SUMMARY_BY_EVENT_NAME) >=
|
||||
# - COUNT/SUM/MAX(EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME) >=
|
||||
# COUNT/SUM/MAX(EVENTS_WAITS_SUMMARY_BY_INSTANCE)
|
||||
# - MIN(EVENTS_WAITS_SUMMARY_BY_EVENT_NAME) <=
|
||||
# - MIN(EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME) <=
|
||||
# MIN(EVENTS_WAITS_SUMMARY_BY_INSTANCE)
|
||||
# There will be equality only when an instrument instance
|
||||
# is not removed, which is next to impossible to predictably guarantee
|
||||
@ -80,9 +80,9 @@ set @dump_all=FALSE;
|
||||
# Both cause a row to be deleted from EVENTS_WAITS_SUMMARY_BY_INSTANCE.
|
||||
|
||||
# Likewise:
|
||||
# - COUNT/SUM/MAX(EVENTS_WAITS_SUMMARY_BY_EVENT_NAME) >=
|
||||
# - COUNT/SUM/MAX(EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME) >=
|
||||
# COUNT/SUM/MAX(EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME)
|
||||
# - MIN(EVENTS_WAITS_SUMMARY_BY_EVENT_NAME) <=
|
||||
# - MIN(EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME) <=
|
||||
# MIN(EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME)
|
||||
# There will be equality only when no thread is removed,
|
||||
# that is if no thread disconnects, or no sub thread (for example insert
|
||||
@ -131,14 +131,14 @@ OR @dump_all;
|
||||
--echo "Verifying waits aggregate consistency (instance)"
|
||||
|
||||
SELECT EVENT_NAME, e.SUM_TIMER_WAIT, SUM(i.SUM_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE AS i USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
HAVING (e.SUM_TIMER_WAIT < SUM(i.SUM_TIMER_WAIT))
|
||||
OR @dump_all;
|
||||
|
||||
SELECT EVENT_NAME, e.MIN_TIMER_WAIT, MIN(i.MIN_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE AS i USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
HAVING (e.MIN_TIMER_WAIT > MIN(i.MIN_TIMER_WAIT))
|
||||
@ -146,7 +146,7 @@ AND (MIN(i.MIN_TIMER_WAIT) != 0)
|
||||
OR @dump_all;
|
||||
|
||||
SELECT EVENT_NAME, e.MAX_TIMER_WAIT, MAX(i.MAX_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_INSTANCE AS i USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
HAVING (e.MAX_TIMER_WAIT < MAX(i.MAX_TIMER_WAIT))
|
||||
@ -155,7 +155,7 @@ OR @dump_all;
|
||||
--echo "Verifying waits aggregate consistency (thread)"
|
||||
|
||||
SELECT EVENT_NAME, e.SUM_TIMER_WAIT, SUM(t.SUM_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME AS t
|
||||
USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
@ -163,7 +163,7 @@ HAVING (e.SUM_TIMER_WAIT < SUM(t.SUM_TIMER_WAIT))
|
||||
OR @dump_all;
|
||||
|
||||
SELECT EVENT_NAME, e.MIN_TIMER_WAIT, MIN(t.MIN_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME AS t
|
||||
USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
@ -172,7 +172,7 @@ AND (MIN(t.MIN_TIMER_WAIT) != 0)
|
||||
OR @dump_all;
|
||||
|
||||
SELECT EVENT_NAME, e.MAX_TIMER_WAIT, MAX(t.MAX_TIMER_WAIT)
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME AS e
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME AS e
|
||||
JOIN performance_schema.EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME AS t
|
||||
USING (EVENT_NAME)
|
||||
GROUP BY EVENT_NAME
|
||||
|
49
mysql-test/suite/perfschema/t/bad_option_3.test
Normal file
49
mysql-test/suite/perfschema/t/bad_option_3.test
Normal file
@ -0,0 +1,49 @@
|
||||
# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
# Check error handling for invalid server start options
|
||||
|
||||
--source include/not_embedded.inc
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
let $outfile= $MYSQLTEST_VARDIR/tmp/bad_option_3.txt;
|
||||
--error 0,1
|
||||
--remove_file $outfile
|
||||
--error 2
|
||||
--exec $MYSQLD_BOOTSTRAP_CMD --loose-console -a -x > $outfile 2>&1
|
||||
|
||||
perl;
|
||||
use strict;
|
||||
use warnings;
|
||||
my $fname= "$ENV{'MYSQLTEST_VARDIR'}/tmp/bad_option_3.txt";
|
||||
open(FILE, "<", $fname) or die;
|
||||
my @lines= <FILE>;
|
||||
# those must be in the file for the test to pass
|
||||
my @patterns=
|
||||
("unknown option '-x'",
|
||||
"Aborting");
|
||||
foreach my $one_line (@lines)
|
||||
{
|
||||
foreach my $one_pattern (@patterns)
|
||||
{
|
||||
# print pattern, not line, to get a stable output
|
||||
print "Found: $one_pattern\n" if ($one_line =~ /$one_pattern/);
|
||||
}
|
||||
}
|
||||
close FILE;
|
||||
EOF
|
||||
--remove_file $outfile
|
||||
|
49
mysql-test/suite/perfschema/t/bad_option_4.test
Normal file
49
mysql-test/suite/perfschema/t/bad_option_4.test
Normal file
@ -0,0 +1,49 @@
|
||||
# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
# Check error handling for invalid server start options
|
||||
|
||||
--source include/not_embedded.inc
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
let $outfile= $MYSQLTEST_VARDIR/tmp/bad_option_4.txt;
|
||||
--error 0,1
|
||||
--remove_file $outfile
|
||||
--error 1
|
||||
--exec $MYSQLD_BOOTSTRAP_CMD --loose-console -a -h bad_option_h_param > $outfile 2>&1
|
||||
|
||||
perl;
|
||||
use strict;
|
||||
use warnings;
|
||||
my $fname= "$ENV{'MYSQLTEST_VARDIR'}/tmp/bad_option_4.txt";
|
||||
open(FILE, "<", $fname) or die;
|
||||
my @lines= <FILE>;
|
||||
# those must be in the file for the test to pass
|
||||
my @patterns=
|
||||
("Can't change dir to.*bad_option_h_param",
|
||||
"Aborting");
|
||||
foreach my $one_line (@lines)
|
||||
{
|
||||
foreach my $one_pattern (@patterns)
|
||||
{
|
||||
# print pattern, not line, to get a stable output
|
||||
print "Found: $one_pattern\n" if ($one_line =~ /$one_pattern/);
|
||||
}
|
||||
}
|
||||
close FILE;
|
||||
EOF
|
||||
--remove_file $outfile
|
||||
|
52
mysql-test/suite/perfschema/t/bad_option_5.test
Normal file
52
mysql-test/suite/perfschema/t/bad_option_5.test
Normal file
@ -0,0 +1,52 @@
|
||||
# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
# Check error handling for invalid server start options
|
||||
|
||||
--source include/not_embedded.inc
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
let $outfile= $MYSQLTEST_VARDIR/tmp/bad_option_5.txt;
|
||||
--error 0,1
|
||||
--remove_file $outfile
|
||||
--error 2
|
||||
--exec $MYSQLD_BOOTSTRAP_CMD --loose-console -aXbroken > $outfile 2>&1
|
||||
|
||||
# -aXbroken should be parsed as -a -Xbroken, or --ansi -Xbroken,
|
||||
# therefore the -X option is what the server should complain about
|
||||
|
||||
perl;
|
||||
use strict;
|
||||
use warnings;
|
||||
my $fname= "$ENV{'MYSQLTEST_VARDIR'}/tmp/bad_option_5.txt";
|
||||
open(FILE, "<", $fname) or die;
|
||||
my @lines= <FILE>;
|
||||
# those must be in the file for the test to pass
|
||||
my @patterns=
|
||||
("unknown option '-X'",
|
||||
"Aborting");
|
||||
foreach my $one_line (@lines)
|
||||
{
|
||||
foreach my $one_pattern (@patterns)
|
||||
{
|
||||
# print pattern, not line, to get a stable output
|
||||
print "Found: $one_pattern\n" if ($one_line =~ /$one_pattern/);
|
||||
}
|
||||
}
|
||||
close FILE;
|
||||
EOF
|
||||
--remove_file $outfile
|
||||
|
@ -19,13 +19,16 @@
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
alter table performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME add column foo integer;
|
||||
alter table performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
add column foo integer;
|
||||
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
truncate table performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
ALTER TABLE performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME ADD INDEX test_index(EVENT_NAME);
|
||||
ALTER TABLE performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
ADD INDEX test_index(EVENT_NAME);
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME(EVENT_NAME);
|
||||
CREATE UNIQUE INDEX test_index
|
||||
ON performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME(EVENT_NAME);
|
||||
|
@ -1,32 +0,0 @@
|
||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
|
||||
--source include/not_embedded.inc
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
--replace_result '\'setup_objects' '\'SETUP_OBJECTS'
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
alter table performance_schema.SETUP_OBJECTS add column foo integer;
|
||||
|
||||
truncate table performance_schema.SETUP_OBJECTS;
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
ALTER TABLE performance_schema.SETUP_OBJECTS ADD INDEX test_index(OBJECT_NAME);
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.SETUP_OBJECTS(OBJECT_NAME);
|
||||
|
@ -19,14 +19,14 @@
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
alter table performance_schema.PROCESSLIST add column foo integer;
|
||||
alter table performance_schema.THREADS add column foo integer;
|
||||
|
||||
-- error ER_WRONG_PERFSCHEMA_USAGE
|
||||
truncate table performance_schema.PROCESSLIST;
|
||||
truncate table performance_schema.THREADS;
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
ALTER TABLE performance_schema.PROCESSLIST ADD INDEX test_index(ID);
|
||||
ALTER TABLE performance_schema.THREADS ADD INDEX test_index(ID);
|
||||
|
||||
-- error ER_DBACCESS_DENIED_ERROR
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.PROCESSLIST(ID);
|
||||
CREATE UNIQUE INDEX test_index ON performance_schema.THREADS(ID);
|
||||
|
@ -19,44 +19,44 @@
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
--replace_column 1 # 2 # 3 # 4 # 5 # 6 #
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
where event_name like 'Wait/Synch/%' limit 1;
|
||||
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
select * from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
where event_name='FOO';
|
||||
|
||||
--replace_result '\'events_waits_summary_by_event_name' '\'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
--replace_result '\'events_waits_summary_global_by_event_name' '\'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
insert into performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
insert into performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
set event_name='FOO', count_star=1, sum_timer_wait=2, min_timer_wait=3,
|
||||
avg_timer_wait=4, max_timer_wait=5;
|
||||
|
||||
--replace_result '\'events_waits_summary_by_event_name' '\'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
--replace_result '\'events_waits_summary_global_by_event_name' '\'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
set count_star=12;
|
||||
|
||||
--replace_result '\'events_waits_summary_by_event_name' '\'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
--replace_result '\'events_waits_summary_global_by_event_name' '\'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
update performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
set count_star=12 where event_name like "FOO";
|
||||
|
||||
--replace_result '\'events_waits_summary_by_event_name' '\'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
--replace_result '\'events_waits_summary_global_by_event_name' '\'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
where count_star=1;
|
||||
|
||||
--replace_result '\'events_waits_summary_by_event_name' '\'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
--replace_result '\'events_waits_summary_global_by_event_name' '\'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
delete from performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
|
||||
--replace_result '\'events_waits_summary_by_event_name' '\'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
--replace_result '\'events_waits_summary_global_by_event_name' '\'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
-- error ER_TABLEACCESS_DENIED_ERROR
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME READ;
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME READ;
|
||||
UNLOCK TABLES;
|
||||
|
||||
--replace_result '\'events_waits_summary_by_event_name' '\'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME'
|
||||
--replace_result '\'events_waits_summary_global_by_event_name' '\'EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME'
|
||||
-- error ER_TABLEACCESS_DENIED_ERROR
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME WRITE;
|
||||
LOCK TABLES performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME WRITE;
|
||||
UNLOCK TABLES;
|
||||
|
@ -1,75 +0,0 @@
|
||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
|
||||
--source include/not_embedded.inc
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
|
||||
select * from performance_schema.SETUP_OBJECTS
|
||||
where object_type = 'TABLE';
|
||||
|
||||
select * from performance_schema.SETUP_OBJECTS
|
||||
where enabled='YES';
|
||||
|
||||
# Not implemented yet
|
||||
--replace_result '\'setup_objects' '\'SETUP_OBJECTS'
|
||||
--error ER_ILLEGAL_HA
|
||||
insert into performance_schema.SETUP_OBJECTS
|
||||
set object_type='TABLE', object_schema='FOO', object_name='BAR',
|
||||
enabled='YES', timed='YES', aggregated='YES';
|
||||
|
||||
# Not implemented yet
|
||||
# --error ER_ILLEGAL_HA
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set object_type='TABLE';
|
||||
|
||||
# Not implemented yet
|
||||
# --error ER_ILLEGAL_HA
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set object_schema='ILLEGAL';
|
||||
|
||||
# Not implemented yet
|
||||
# --error ER_ILLEGAL_HA
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set object_name='ILLEGAL';
|
||||
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set enabled='NO';
|
||||
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set timed='NO';
|
||||
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set aggregated='NO';
|
||||
|
||||
select * from performance_schema.SETUP_OBJECTS;
|
||||
|
||||
update performance_schema.SETUP_OBJECTS
|
||||
set enabled='YES', timed='YES', aggregated='YES';
|
||||
|
||||
delete from performance_schema.SETUP_OBJECTS
|
||||
where object_type = 'TABLE';
|
||||
|
||||
delete from performance_schema.SETUP_OBJECTS;
|
||||
|
||||
LOCK TABLES performance_schema.SETUP_OBJECTS READ;
|
||||
UNLOCK TABLES;
|
||||
|
||||
LOCK TABLES performance_schema.SETUP_OBJECTS WRITE;
|
||||
UNLOCK TABLES;
|
||||
|
@ -19,43 +19,43 @@
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
--replace_column 1 # 2 # 3 #
|
||||
select * from performance_schema.PROCESSLIST
|
||||
select * from performance_schema.THREADS
|
||||
where name like 'Thread/%' limit 1;
|
||||
|
||||
select * from performance_schema.PROCESSLIST
|
||||
select * from performance_schema.THREADS
|
||||
where name='FOO';
|
||||
|
||||
--replace_result '\'processlist' '\'PROCESSLIST'
|
||||
--replace_result '\'threads' '\'THREADS'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
insert into performance_schema.PROCESSLIST
|
||||
insert into performance_schema.THREADS
|
||||
set name='FOO', thread_id=1, id=2;
|
||||
|
||||
--replace_result '\'processlist' '\'PROCESSLIST'
|
||||
--replace_result '\'threads' '\'THREADS'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
update performance_schema.PROCESSLIST
|
||||
update performance_schema.THREADS
|
||||
set thread_id=12;
|
||||
|
||||
--replace_result '\'processlist' '\'PROCESSLIST'
|
||||
--replace_result '\'threads' '\'THREADS'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
update performance_schema.PROCESSLIST
|
||||
update performance_schema.THREADS
|
||||
set thread_id=12 where name like "FOO";
|
||||
|
||||
--replace_result '\'processlist' '\'PROCESSLIST'
|
||||
--replace_result '\'threads' '\'THREADS'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
delete from performance_schema.PROCESSLIST
|
||||
delete from performance_schema.THREADS
|
||||
where id=1;
|
||||
|
||||
--replace_result '\'processlist' '\'PROCESSLIST'
|
||||
--replace_result '\'threads' '\'THREADS'
|
||||
--error ER_TABLEACCESS_DENIED_ERROR
|
||||
delete from performance_schema.PROCESSLIST;
|
||||
delete from performance_schema.THREADS;
|
||||
|
||||
--replace_result '\'processlist' '\'PROCESSLIST'
|
||||
--replace_result '\'threads' '\'THREADS'
|
||||
-- error ER_TABLEACCESS_DENIED_ERROR
|
||||
LOCK TABLES performance_schema.PROCESSLIST READ;
|
||||
LOCK TABLES performance_schema.THREADS READ;
|
||||
UNLOCK TABLES;
|
||||
|
||||
--replace_result '\'processlist' '\'PROCESSLIST'
|
||||
--replace_result '\'threads' '\'THREADS'
|
||||
-- error ER_TABLEACCESS_DENIED_ERROR
|
||||
LOCK TABLES performance_schema.PROCESSLIST WRITE;
|
||||
LOCK TABLES performance_schema.THREADS WRITE;
|
||||
UNLOCK TABLES;
|
||||
|
@ -144,7 +144,7 @@ WHERE FILE_NAME LIKE CONCAT('%', @@tmpdir, '%') ORDER BY NULL;
|
||||
#
|
||||
--disable_result_log
|
||||
SELECT EVENT_NAME, COUNT_STAR, AVG_TIMER_WAIT, SUM_TIMER_WAIT
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_BY_EVENT_NAME
|
||||
FROM performance_schema.EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME
|
||||
WHERE COUNT_STAR > 0
|
||||
ORDER BY SUM_TIMER_WAIT DESC
|
||||
LIMIT 10;
|
||||
@ -158,7 +158,7 @@ LIMIT 10;
|
||||
SELECT i.user, SUM(TIMER_WAIT) SUM_WAIT
|
||||
# ((TIME_TO_SEC(TIMEDIFF(NOW(), i.startup_time)) * 1000) / SUM(TIMER_WAIT)) * 100 WAIT_PERCENTAGE
|
||||
FROM performance_schema.EVENTS_WAITS_HISTORY_LONG h
|
||||
INNER JOIN performance_schema.PROCESSLIST p USING (THREAD_ID)
|
||||
INNER JOIN performance_schema.THREADS p USING (THREAD_ID)
|
||||
LEFT JOIN information_schema.PROCESSLIST i USING (ID)
|
||||
GROUP BY i.user
|
||||
ORDER BY SUM_WAIT DESC
|
||||
@ -171,7 +171,7 @@ LIMIT 20;
|
||||
--disable_result_log
|
||||
SELECT h.EVENT_NAME, SUM(h.TIMER_WAIT) TOTAL_WAIT
|
||||
FROM performance_schema.EVENTS_WAITS_HISTORY_LONG h
|
||||
INNER JOIN performance_schema.PROCESSLIST p USING (THREAD_ID)
|
||||
INNER JOIN performance_schema.THREADS p USING (THREAD_ID)
|
||||
WHERE p.ID = 1
|
||||
GROUP BY h.EVENT_NAME
|
||||
HAVING TOTAL_WAIT > 0;
|
||||
@ -184,7 +184,7 @@ HAVING TOTAL_WAIT > 0;
|
||||
--disable_result_log
|
||||
SELECT i.user, h.operation, SUM(NUMBER_OF_BYTES) bytes
|
||||
FROM performance_schema.EVENTS_WAITS_HISTORY_LONG h
|
||||
INNER JOIN performance_schema.PROCESSLIST p USING (THREAD_ID)
|
||||
INNER JOIN performance_schema.THREADS p USING (THREAD_ID)
|
||||
LEFT JOIN information_schema.PROCESSLIST i USING (ID)
|
||||
GROUP BY i.user, h.operation
|
||||
HAVING BYTES > 0
|
||||
|
@ -27,7 +27,7 @@
|
||||
--disable_result_log
|
||||
SELECT EVENT_ID FROM performance_schema.EVENTS_WAITS_CURRENT
|
||||
WHERE THREAD_ID IN
|
||||
(SELECT THREAD_ID FROM performance_schema.PROCESSLIST)
|
||||
(SELECT THREAD_ID FROM performance_schema.THREADS)
|
||||
AND EVENT_NAME IN
|
||||
(SELECT NAME FROM performance_schema.SETUP_INSTRUMENTS
|
||||
WHERE NAME LIKE "wait/synch/%")
|
||||
|
@ -45,10 +45,10 @@ show variables like "performance_schema_max_thread%";
|
||||
|
||||
# Verification : in this main thread
|
||||
|
||||
select count(*) from performance_schema.PROCESSLIST
|
||||
select count(*) from performance_schema.THREADS
|
||||
where name like "thread/sql/main";
|
||||
|
||||
select count(*) from performance_schema.PROCESSLIST
|
||||
select count(*) from performance_schema.THREADS
|
||||
where name like "thread/sql/OneConnection";
|
||||
|
||||
select event_name, operation,
|
||||
|
@ -29,18 +29,17 @@ show create table COND_INSTANCES;
|
||||
show create table EVENTS_WAITS_CURRENT;
|
||||
show create table EVENTS_WAITS_HISTORY;
|
||||
show create table EVENTS_WAITS_HISTORY_LONG;
|
||||
show create table EVENTS_WAITS_SUMMARY_BY_EVENT_NAME;
|
||||
show create table EVENTS_WAITS_SUMMARY_BY_INSTANCE;
|
||||
show create table EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME;
|
||||
show create table EVENTS_WAITS_SUMMARY_GLOBAL_BY_EVENT_NAME;
|
||||
show create table FILE_INSTANCES;
|
||||
show create table FILE_SUMMARY_BY_EVENT_NAME;
|
||||
show create table FILE_SUMMARY_BY_INSTANCE;
|
||||
show create table MUTEX_INSTANCES;
|
||||
show create table PERFORMANCE_TIMERS;
|
||||
show create table PROCESSLIST;
|
||||
show create table RWLOCK_INSTANCES;
|
||||
show create table SETUP_CONSUMERS;
|
||||
show create table SETUP_INSTRUMENTS;
|
||||
show create table SETUP_OBJECTS;
|
||||
show create table SETUP_TIMERS;
|
||||
show create table THREADS;
|
||||
|
||||
|
@ -45,7 +45,7 @@ LIMIT 1;
|
||||
--replace_column 1 [EVENT_ID]
|
||||
SELECT EVENT_ID FROM performance_schema.EVENTS_WAITS_CURRENT
|
||||
WHERE THREAD_ID IN
|
||||
(SELECT THREAD_ID FROM performance_schema.PROCESSLIST)
|
||||
(SELECT THREAD_ID FROM performance_schema.THREADS)
|
||||
AND EVENT_NAME IN
|
||||
(SELECT NAME FROM performance_schema.SETUP_INSTRUMENTS
|
||||
WHERE NAME LIKE "wait/synch/%")
|
||||
@ -138,7 +138,7 @@ delimiter |;
|
||||
|
||||
CREATE PROCEDURE t_ps_proc(IN tid INT, OUT pid INT)
|
||||
BEGIN
|
||||
SELECT id FROM performance_schema.PROCESSLIST
|
||||
SELECT id FROM performance_schema.THREADS
|
||||
WHERE THREAD_ID = tid INTO pid;
|
||||
END;
|
||||
|
||||
@ -157,7 +157,7 @@ delimiter |;
|
||||
|
||||
CREATE FUNCTION t_ps_func(tid INT) RETURNS int
|
||||
BEGIN
|
||||
return (SELECT id FROM performance_schema.PROCESSLIST
|
||||
return (SELECT id FROM performance_schema.THREADS
|
||||
WHERE THREAD_ID = tid);
|
||||
END;
|
||||
|
||||
|
1
mysql-test/suite/perfschema/t/short_option_1-master.opt
Normal file
1
mysql-test/suite/perfschema/t/short_option_1-master.opt
Normal file
@ -0,0 +1 @@
|
||||
-a -n -Cutf8 --collation=utf8_bin -l -T12 -W3
|
35
mysql-test/suite/perfschema/t/short_option_1.test
Normal file
35
mysql-test/suite/perfschema/t/short_option_1.test
Normal file
@ -0,0 +1,35 @@
|
||||
# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
# Check server start for short server start options
|
||||
|
||||
select 'Ok, the server started' as result;
|
||||
|
||||
# See the associated -master.opt file.
|
||||
|
||||
select @@SQL_MODE;
|
||||
show variables like 'sql_mode';
|
||||
|
||||
select @@character_set_server;
|
||||
show variables like 'character_set_system';
|
||||
|
||||
show variables like 'log';
|
||||
show variables like 'general_log';
|
||||
|
||||
show variables like 'new';
|
||||
|
||||
show variables like 'log_warnings';
|
||||
|
1
mysql-test/suite/perfschema/t/short_option_2-master.opt
Normal file
1
mysql-test/suite/perfschema/t/short_option_2-master.opt
Normal file
@ -0,0 +1 @@
|
||||
-aW5
|
29
mysql-test/suite/perfschema/t/short_option_2.test
Normal file
29
mysql-test/suite/perfschema/t/short_option_2.test
Normal file
@ -0,0 +1,29 @@
|
||||
# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
# Check server start for short server start options
|
||||
|
||||
select 'Ok, the server started' as result;
|
||||
|
||||
# See the associated -master.opt file.
|
||||
# -aW5 should be parsed as -a -W5, which are two separate short options
|
||||
# stuffed inside a single argv[i] argument.
|
||||
|
||||
# Should contain ANSI, since we started the server with -a (stands for --ansi)
|
||||
select @@SQL_MODE;
|
||||
|
||||
# Should be 5, since we started the server with -W5
|
||||
select @@log_warnings;
|
@ -31,7 +31,7 @@ select variable_value > 0 from information_schema.global_status
|
||||
where variable_name like 'PERFORMANCE_SCHEMA_THREAD_CLASSES_LOST';
|
||||
|
||||
# Expect no instances
|
||||
select count(*) from performance_schema.PROCESSLIST;
|
||||
select count(*) from performance_schema.THREADS;
|
||||
|
||||
# Expect no instances lost
|
||||
show status like "performance_schema_thread_instances_lost";
|
||||
|
@ -33,7 +33,7 @@ show status like "performance_schema_thread_classes_lost";
|
||||
# Expect no instances
|
||||
show variables like "performance_schema_max_thread_instances";
|
||||
|
||||
select count(*) from performance_schema.PROCESSLIST;
|
||||
select count(*) from performance_schema.THREADS;
|
||||
|
||||
# Expect instances lost
|
||||
select variable_value > 0 from information_schema.global_status
|
||||
|
@ -30,14 +30,14 @@ connect (con1, localhost, root, , );
|
||||
|
||||
let $con1_ID=`select connection_id()`;
|
||||
|
||||
let $con1_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con1_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID = connection_id()`;
|
||||
|
||||
connect (con2, localhost, root, , );
|
||||
|
||||
let $con2_ID=`select connection_id()`;
|
||||
|
||||
let $con2_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con2_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID = connection_id()`;
|
||||
|
||||
connection default;
|
||||
@ -58,7 +58,7 @@ connect (con3, localhost, root, , );
|
||||
|
||||
let $con3_ID=`select connection_id()`;
|
||||
|
||||
let $con3_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con3_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID = connection_id()`;
|
||||
|
||||
disconnect con3;
|
||||
@ -82,14 +82,14 @@ connect (con1, localhost, root, , );
|
||||
|
||||
let $con1_ID=`select connection_id()`;
|
||||
|
||||
let $con1_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con1_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID = connection_id()`;
|
||||
|
||||
connect (con2, localhost, root, , );
|
||||
|
||||
let $con2_ID=`select connection_id()`;
|
||||
|
||||
let $con2_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con2_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID = connection_id()`;
|
||||
|
||||
connection default;
|
||||
@ -108,7 +108,7 @@ connect (con3, localhost, root, , );
|
||||
|
||||
let $con3_ID=`select connection_id()`;
|
||||
|
||||
let $con3_THREAD_ID=`select thread_id from performance_schema.PROCESSLIST
|
||||
let $con3_THREAD_ID=`select thread_id from performance_schema.THREADS
|
||||
where ID = connection_id()`;
|
||||
|
||||
disconnect con3;
|
||||
|
Reference in New Issue
Block a user