events
包含有关系统中发生的事件数量的信息。例如,在该表中,您可以找到自 ClickHouse 服务器启动以来处理了多少个 SELECT
查询。
列
您可以在源文件 src/Common/ProfileEvents.cpp 中找到所有支持的事件。
示例
SELECT * FROM system.events LIMIT 5
┌─event─────────────────────────────────┬─value─┬─description────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│ Query │ 12 │ Number of queries to be interpreted and potentially executed. Does not include queries that failed to parse or were rejected due to AST size limits, quota limits or limits on the number of simultaneously running queries. May include internal queries initiated by ClickHouse itself. Does not count subqueries. │
│ SelectQuery │ 8 │ Same as Query, but only for SELECT queries. │
│ FileOpen │ 73 │ Number of files opened. │
│ ReadBufferFromFileDescriptorRead │ 155 │ Number of reads (read/pread) from a file descriptor. Does not include sockets. │
│ ReadBufferFromFileDescriptorReadBytes │ 9931 │ Number of bytes read from file descriptors. If the file is compressed, this will show the compressed data size. │
└───────────────────────────────────────┴───────┴────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
另请参阅
- system.asynchronous_metrics — 包含定期计算的指标。
- system.metrics — 包含即时计算的指标。
- system.metric_log — 包含来自表
system.metrics
和system.events
的指标值的记录。 - 监控 — ClickHouse 监控的基本概念。