Using performance_schema
You can inspect the internal execution of the server at runtime using performance_schema. This should not be confused with information schema, which is used to inspect metadata.
There are many event consumers in performance_schema that influence the timings of a server, such as a function call, a wait for the operating system, a stage of an SQL statement execution (say, parsing or sorting), a single statement, or a group of statements. All the collected information is stored in performance_schema and is not replicated.
performance_schema is enabled by default; if you want to disable it, you can set performance_schema=OFF in the my.cnf file. By default, not all the consumers and instruments are enabled; you can turn ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access