Description:
The documentation provides examples that do not work on version 5.7 unless show_compatibility_56 is enabled.
The performance_schema examples need the performance_schema prefix or a USE performance_schema statement.
Excerpts from
https://dev.mysql.com/doc/refman/5.7/en/innodb-preload-buffer-pool.html
Displaying Buffer Pool Dump Progress
SELECT variable_value FROM information_schema.global_status WHERE
variable_name = 'INNODB_BUFFER_POOL_DUMP_STATUS';
...
Displaying Buffer Pool Load Progress
SELECT variable_value FROM information_schema.global_status WHERE
variable_name = 'INNODB_BUFFER_POOL_LOAD_STATUS';
...
The examples in the section "Monitoring Buffer Pool Load Progress Using Performance Schema" are missing the performance_schema prefix or a USE performance_schema statement. Here is an excerpt from the manual
Enable the stage/innodb/buffer pool load instrument:
mysql> UPDATE setup_instruments SET ENABLED = 'YES' WHERE NAME LIKE 'stage/innodb/buffer%';
Enable the stage event consumer tables, which include events_stages_current, events_stages_history, and events_stages_history_long.
mysql> UPDATE setup_consumers SET ENABLED = 'YES' WHERE NAME LIKE '%stages%';
...
The statements in the provided examples fail.
How to repeat:
SELECT variable_value FROM information_schema.global_status WHERE
-> variable_name = 'INNODB_BUFFER_POOL_LOAD_STATUS';
ERROR 3167 (HY000): The 'INFORMATION_SCHEMA.GLOBAL_STATUS' feature is disabled; see the documentation for 'show_compatibility_56'
UPDATE setup_instruments SET ENABLED = 'YES' WHERE NAME LIKE 'stage/innodb/buffer%';
ERROR 1046 (3D000): No database selected
UPDATE setup_consumers SET ENABLED = 'YES' WHERE NAME LIKE '%stages%';
ERROR 1046 (3D000): No database selected
Suggested fix:
Update the documentation to provide guidance that the show_compatibility_56 feature is required for the examples that won't work on version 5.7.
Add the performance_schema prefix or a USE performance_schema statement to the examples.