| 1 |
select * from performance_schema.file_instances limit 1; |
| 2 |
select * from performance_schema.file_instances |
| 3 |
where file_name='FOO'; |
| 4 |
insert into performance_schema.file_instances |
| 5 |
set file_name='FOO', event_name='BAR', open_count=12; |
| 6 |
ERROR 42000: INSERT command denied to user 'root'@'localhost' for table `performance_schema`.`file_instances` |
| 7 |
update performance_schema.file_instances |
| 8 |
set file_name='FOO'; |
| 9 |
ERROR 42000: UPDATE command denied to user 'root'@'localhost' for table `performance_schema`.`file_instances` |
| 10 |
delete from performance_schema.file_instances |
| 11 |
where event_name like "wait/%"; |
| 12 |
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table `performance_schema`.`file_instances` |
| 13 |
delete from performance_schema.file_instances; |
| 14 |
ERROR 42000: DELETE command denied to user 'root'@'localhost' for table `performance_schema`.`file_instances` |
| 15 |
LOCK TABLES performance_schema.file_instances READ; |
| 16 |
ERROR 42000: SELECT, LOCK TABLES command denied to user 'root'@'localhost' for table `performance_schema`.`file_instances` |
| 17 |
UNLOCK TABLES; |
| 18 |
LOCK TABLES performance_schema.file_instances WRITE; |
| 19 |
ERROR 42000: SELECT, LOCK TABLES command denied to user 'root'@'localhost' for table `performance_schema`.`file_instances` |
| 20 |
UNLOCK TABLES; |
| 21 |
# |
| 22 |
# MDEV-25325 column_comment for performance_schema tables |
| 23 |
# |
| 24 |
select column_name, column_comment |
| 25 |
from information_schema.columns |
| 26 |
where table_schema='performance_schema' and table_name='file_instances'; |
| 27 |
column_name column_comment |
| 28 |
FILE_NAME File name. |
| 29 |
EVENT_NAME Instrument name associated with the file. |
| 30 |
OPEN_COUNT Open handles on the file. A value of greater than zero means that the file is currently open. |
| 31 |
### |
| 32 |
### Bug#26152751: INNODB LEAKS MEMORY, PERFORMANCE_SCHEMA FILE_INSTANCES |
| 33 |
### #SQL-IB3129987-252773.IBD |
| 34 |
### |
| 35 |
CREATE DATABASE db_26152751; |
| 36 |
USE db_26152751; |
| 37 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 38 |
FILE_NAME |
| 39 |
CREATE TABLE t_db_26152751 (a INT) ENGINE=MYISAM; |
| 40 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 41 |
FILE_NAME |
| 42 |
t_db_26152751.MYD |
| 43 |
t_db_26152751.MYI |
| 44 |
t_db_26152751.frm |
| 45 |
RENAME TABLE t_db_26152751 to t_db_26152751_new; |
| 46 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 47 |
FILE_NAME |
| 48 |
t_db_26152751_new.MYD |
| 49 |
t_db_26152751_new.MYI |
| 50 |
t_db_26152751_new.frm |
| 51 |
RENAME TABLE t_db_26152751_new to t_db_26152751; |
| 52 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 53 |
FILE_NAME |
| 54 |
t_db_26152751.MYD |
| 55 |
t_db_26152751.MYI |
| 56 |
t_db_26152751.frm |
| 57 |
ALTER TABLE t_db_26152751 ADD COLUMN b INT; |
| 58 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 59 |
FILE_NAME |
| 60 |
t_db_26152751.frm |
| 61 |
t_db_26152751.MYD |
| 62 |
t_db_26152751.MYI |
| 63 |
DROP TABLE t_db_26152751; |
| 64 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 65 |
FILE_NAME |
| 66 |
CREATE TABLE t_db_26152751 (a INT) ENGINE=INNODB; |
| 67 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 68 |
FILE_NAME |
| 69 |
t_db_26152751.frm |
| 70 |
t_db_26152751.ibd |
| 71 |
RENAME TABLE t_db_26152751 to t_db_26152751_new; |
| 72 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 73 |
FILE_NAME |
| 74 |
t_db_26152751_new.frm |
| 75 |
t_db_26152751_new.ibd |
| 76 |
RENAME TABLE t_db_26152751_new to t_db_26152751; |
| 77 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 78 |
FILE_NAME |
| 79 |
t_db_26152751.frm |
| 80 |
t_db_26152751.ibd |
| 81 |
ALTER TABLE t_db_26152751 ADD COLUMN b INT; |
| 82 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 83 |
FILE_NAME |
| 84 |
t_db_26152751.frm |
| 85 |
t_db_26152751.ibd |
| 86 |
DROP TABLE t_db_26152751; |
| 87 |
SELECT FILE_NAME FROM performance_schema.file_instances WHERE FILE_NAME LIKE "%t_db_26152751%" ORDER BY FILE_NAME; |
| 88 |
FILE_NAME |
| 89 |
DROP DATABASE db_26152751; |
| 90 |
# |
| 91 |
# MDEV-25325 column_comment for performance_schema tables |
| 92 |
# |
| 93 |
select column_name, column_comment |
| 94 |
from information_schema.columns |
| 95 |
where table_schema='performance_schema' and table_name='file_instances'; |
| 96 |
column_name column_comment |
| 97 |
FILE_NAME File name. |
| 98 |
EVENT_NAME Instrument name associated with the file. |
| 99 |
OPEN_COUNT Open handles on the file. A value of greater than zero means that the file is currently open. |