8.4 中文镜像

MySQL 8.4 参考手册 · 中文镜像

正文为中文,英文原文默认隐藏。点击任意中文段落即可展开 / 收起对应英文原文。

打开官方英文原文 ↗

译文由机器翻译生成,仅供理解参考;有疑问请以官方英文原文为准。

中文点击中文段落可显示 / 隐藏英文原文本页译文覆盖 100%

30.4.3 sys 架构视图30.4.3 sys Schema Views

下面各节描述了 sys 模式视图。The following sections describe sys schema views.

sys 模式包含许多以各种方式汇总性能模式表的视图。大多数这些视图都是成对出现的,其中一个成员的名称与另一个成员相同,只是在前面加上 x$ 前缀。例如,host_summary_by_file_io 视图汇总按主机分组的文件 I/O,并将延迟从皮秒转换为更易读的数值(带单位);The sys schema contains many views that summarize Performance Schema tables in various ways. Most of these views come in pairs, such that one member of the pair has the same name as the other member, plus a x$ prefix. For example, the host_summary_by_file_io view summarizes file I/O grouped by host and displays latencies converted from picoseconds to more readable values (with units);

mysql> SELECT * FROM sys.host_summary_by_file_io;
+------------+-------+------------+
| host       | ios   | io_latency |
+------------+-------+------------+
| localhost  | 67570 | 5.38 s     |
| background |  3468 | 4.18 s     |
+------------+-------+------------+

而x$host_summary_by_file_io 视图汇总相同的数据,但显示未格式化的皮秒延迟:The x$host_summary_by_file_io view summarizes the same data but displays unformatted picosecond latencies:

mysql> SELECT * FROM sys.x$host_summary_by_file_io;
+------------+-------+---------------+
| host       | ios   | io_latency    |
+------------+-------+---------------+
| localhost  | 67574 | 5380678125144 |
| background |  3474 | 4758696829416 |
+------------+-------+---------------+

没有 x$ 前缀的视图旨在提供更用户友好且更易于阅读的输出。带有 x$ 前缀的视图以原始形式显示相同的值,更多用于其他对数据进行处理的工具。The view without the x$ prefix is intended to provide output that is more user friendly and easier to read. The view with the x$ prefix that displays the same values in raw form is intended more for use with other tools that perform their own processing on the data.

没有 x$ 前缀的视图与对应的 x$ 视图在以下方面有所不同:Views without the x$ prefix differ from the corresponding x$ views in these ways: