Skip to content

Commit

Permalink
op-guide, media: fix too large metrics images
Browse files Browse the repository at this point in the history
  • Loading branch information
lilin90 committed Dec 4, 2018
1 parent 78fd96b commit c4e4660
Show file tree
Hide file tree
Showing 28 changed files with 595 additions and 474 deletions.
Binary file added media/pd-dashboard-balance.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-cluster.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-etcd.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-grpc.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-heartbeat.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-hot-region.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-operator.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-scheduler.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/pd-dashboard-tidb.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed media/pd_dashboard.png
Binary file not shown.
Binary file added media/tikv-dashboard-cluster.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-errors.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-local-reader.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-raft-admin.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-raft-message.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-raft-process.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-raft-propose.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-raftio.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-scheduler-batch-get.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-scheduler-cleanup.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-scheduler-commit.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-scheduler.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-server.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/tikv-dashboard-storage.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed media/tikv_dashboard.png
Binary file not shown.
129 changes: 68 additions & 61 deletions op-guide/dashboard-overview-info.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,67 +13,74 @@ category: monitoring

以下为 Overview Dashboard 监控说明:

## 说明

- Services Port Status
- Services Online:各服务在线节点数量
- Services Offline:各服务 Down 掉节点数量
- PD
- Storage Capacity:TiDB 集群总可用数据库空间大小
- Current Storage Size:TiDB 集群目前已用数据库空间大小
- Number of Regions:当前集群的 Region 总量
- Leader Balance Ratio:Leader 数量最多和最少节点相差的百分比,一般小于 5%,节点重启时会有比较大的波动
- Region Balance Ratio:Region 数量最多和最少节点相差的百分比,一般小于 5%,新增/下线节点时相差比较大
- Store Status:集群 TiKV 节点的状态
- Up Stores:正常运行的 TiKV 节点数量
- Disconnect Stores:短时间内通信异常的 TiKV 节点数量
- LowSpace Stores:剩余可用空间小于 80% 的 TiKV 节点数量
- Down Stores:停止工作的 TiKV 节点数量,如果大于 0,说明有节点不正常
- Offline Stores:正在下线的 TiKV 节点数量(正在下线的 TiKV 节点还在提供服务)
- Tombstone Stores:下线成功的 TiKV 节点数量
- 99% completed\_cmds\_duration\_seconds:单位时间内,99% 的 pd-server 请求执行时间小于监控曲线的值,一般 <= 5ms
- handle\_requests\_duration\_seconds:PD 发送请求的网络耗时
- TiDB
- Statement OPS:SQL 执行数量统计(包含 select、insert、update 等)
- Duration:SQL 执行的时间
- QPS By Instance:每个 TiDB 上的 QPS
- Failed Query OPM:失败 SQL 的统计,例如语法错误、主键冲突等
- Connection count:每个 TiDB 的连接数
- Heap Memory Usage:每个 TiDB 使用的堆内存大小
- Transaction OPS:事务执行数量统计
- Transaction Duration:事务执行的时间
- KV Cmd OPS:KV 命令执行数量统计
- KV Cmd Duration 99:KV 命令执行的时间
- PD TSO OPS:TiDB 从 PD 获取 TSO 的数量
- PD TSO Wait Duration:TiDB 从 PD 获取 TS 的时间
- TiClient Region Error OPS:TiKV 返回 Region 相关错误信息的数量
- Lock Resolve OPS:事务冲突相关的数量
- Load Schema Duration:TiDB 从 TiKV 获取 Schema 的时间
- KV Backoff OPS:TiKV 返回错误信息的数量(事务冲突等)
- TiKV
- leader:各个 TiKV 节点上 Leader 的数量分布
- region:各个 TiKV 节点上 Region 的数量分布
- CPU:各个 TiKV 节点的 CPU 使用率
- Memory:各个 TiKV 节点的内存使用量
- store size:各个 TiKV 节点存储的数据量
- cf size:集群不同 CF 存储的数据量
- channel full:正常情况显示 No data,如果有了监控值,说明对应 TiKV 节点的消息处理不过来了
- server report failures:正常情况显示 No data,如果出现了 Unreachable,说明 TiKV 之间通信有问题
- scheduler pending commands:写入堆积的数量,偶尔出现峰值属于正常现象
- coprocessor pending requests:正常情况监控为 0 或者数量很少
- coprocessor executor count:不同类型的查询操作数量
- coprocessor request duration:TiKV 中查询消耗的时间
- raft store CPU:raftstore 线程的 CPU 使用率,目前为单线程,超过 80% 说明使用率很高
- Coprocessor CPU:TiKV 查询线程的 CPU 使用率,和业务相关,复杂查询会使用大量的 CPU 资源
- System Info
- Vcores:CPU 核心数量
- Memory:内存总大小
- CPU Usage:CPU 使用率,最大为 100%
- Load [1m]:1 分钟的负载情况
- Memory Available:剩余内存大小
- Network Traffic:网卡流量统计
- TCP Retrans:网络监控,TCP 相关信息统计
- IO Util:磁盘使用率,最高为 100%,一般到 80% - 90% 就需要考虑加节点
## Services Port Status

- Services Online:各服务在线节点数量
- Services Offline:各服务 Down 掉节点数量

## PD

- Storage Capacity:TiDB 集群总可用数据库空间大小
- Current Storage Size:TiDB 集群目前已用数据库空间大小
- Number of Regions:当前集群的 Region 总量
- Leader Balance Ratio:Leader 数量最多和最少节点相差的百分比,一般小于 5%,节点重启时会有比较大的波动
- Region Balance Ratio:Region 数量最多和最少节点相差的百分比,一般小于 5%,新增/下线节点时相差比较大
- Store Status:集群 TiKV 节点的状态
- Up Stores:正常运行的 TiKV 节点数量
- Disconnect Stores:短时间内通信异常的 TiKV 节点数量
- LowSpace Stores:剩余可用空间小于 80% 的 TiKV 节点数量
- Down Stores:停止工作的 TiKV 节点数量,如果大于 0,说明有节点不正常
- Offline Stores:正在下线的 TiKV 节点数量(正在下线的 TiKV 节点还在提供服务)
- Tombstone Stores:下线成功的 TiKV 节点数量
- 99% completed\_cmds\_duration\_seconds:单位时间内,99% 的 pd-server 请求执行时间小于监控曲线的值,一般 <= 5ms
- handle\_requests\_duration\_seconds:PD 发送请求的网络耗时

## TiDB

- Statement OPS:SQL 执行数量统计(包含 select、insert、update 等)
- Duration:SQL 执行的时间
- QPS By Instance:每个 TiDB 上的 QPS
- Failed Query OPM:失败 SQL 的统计,例如语法错误、主键冲突等
- Connection count:每个 TiDB 的连接数
- Heap Memory Usage:每个 TiDB 使用的堆内存大小
- Transaction OPS:事务执行数量统计
- Transaction Duration:事务执行的时间
- KV Cmd OPS:KV 命令执行数量统计
- KV Cmd Duration 99:KV 命令执行的时间
- PD TSO OPS:TiDB 从 PD 获取 TSO 的数量
- PD TSO Wait Duration:TiDB 从 PD 获取 TS 的时间
- TiClient Region Error OPS:TiKV 返回 Region 相关错误信息的数量
- Lock Resolve OPS:事务冲突相关的数量
- Load Schema Duration:TiDB 从 TiKV 获取 Schema 的时间
- KV Backoff OPS:TiKV 返回错误信息的数量(事务冲突等)

## TiKV

- leader:各个 TiKV 节点上 Leader 的数量分布
- region:各个 TiKV 节点上 Region 的数量分布
- CPU:各个 TiKV 节点的 CPU 使用率
- Memory:各个 TiKV 节点的内存使用量
- store size:各个 TiKV 节点存储的数据量
- cf size:集群不同 CF 存储的数据量
- channel full:正常情况显示 No data,如果有了监控值,说明对应 TiKV 节点的消息处理不过来了
- server report failures:正常情况显示 No data,如果出现了 Unreachable,说明 TiKV 之间通信有问题
- scheduler pending commands:写入堆积的数量,偶尔出现峰值属于正常现象
- coprocessor pending requests:正常情况监控为 0 或者数量很少
- coprocessor executor count:不同类型的查询操作数量
- coprocessor request duration:TiKV 中查询消耗的时间
- raft store CPU:raftstore 线程的 CPU 使用率,目前为单线程,超过 80% 说明使用率很高
- Coprocessor CPU:TiKV 查询线程的 CPU 使用率,和业务相关,复杂查询会使用大量的 CPU 资源

## System Info

- Vcores:CPU 核心数量
- Memory:内存总大小
- CPU Usage:CPU 使用率,最大为 100%
- Load [1m]:1 分钟的负载情况
- Memory Available:剩余内存大小
- Network Traffic:网卡流量统计
- TCP Retrans:网络监控,TCP 相关信息统计
- IO Util:磁盘使用率,最高为 100%,一般到 80% - 90% 就需要考虑加节点

## 图例

Expand Down
197 changes: 113 additions & 84 deletions op-guide/dashboard-pd-info.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,87 +13,116 @@ category: monitoring

以下为 PD Dashboard 监控说明:

## 说明

- Cluster
- PD role:当前 PD 的角色
- Storage capacity:TiDB 集群总可用数据库空间大小
- Current storage size:TiDB 集群目前已用数据库空间大小
- Number of Regions:当前集群的 Region 总量
- Leader balance ratio:Leader 数量最多和最少节点相差的百分比,一般小于 5%,节点重启时会有比较大的波动
- Region balance ratio:Region 数量最多和最少节点相差的百分比,一般小于 5%,新增/下线节点时相差比较大
- Normal stores:处于正常状态的节点数目
- Abnormal stores:处于异常状态的节点数目,正常情况应当为 0
- Current storage usage:TiDB 集群存储空间的使用率
- Current peer count:当前集群 peer 的总量
- Metadata information:记录集群 ID,时间戳和生成的 ID
- Region label isolation level:不同 label 所在的 level 的 Region 数量
- Region health:每个 Region 的状态,通常情况下,pending 的 peer 应该少于 100,miss 的 peer 不能一直大于 0
- Balance
- Store capacity:每个 TiKV 实例的总的空间大小
- Store available:每个 TiKV 实例的可用空间大小
- Store used:每个 TiKV 实例的已使用空间大小
- Size amplification:每个 TiKV 实例的空间放大比率
- Size available ratio:每个 TiKV 实例的可用空间比率
- Store leader score:每个 TiKV 实例的 leader 分数
- Store Region score:每个 TiKV 实例的 Region 分数
- Store leader size:每个 TiKV 实例上所有 leader 的大小
- Store Region size:每个 TiKV 实例上所有 Region 的大小
- Store leader count:每个 TiKV 实例上所有 leader 的数量
- Store Region count:每个 TiKV 实例上所有 Region 的数量
- HotRegion
- Hot write Region's leader distribution:每个 TiKV 实例上是写入热点的 leader 的数量
- Hot write Region's peer distribution:每个 TiKV 实例上是写入热点的 peer 的数量
- Hot write Region's leader written bytes:每个 TiKV 实例上热点的 leader 的写入大小
- Hot write Region's peer written bytes:每个 TiKV 实例上热点的 peer 的写入大小
- Hot read Region's leader distribution:每个 TiKV 实例上是读取热点的 leader 的数量
- Hot read Region's peer distribution:每个 TiKV 实例上是读取热点的 peer 的数量
- Hot read Region's leader read bytes:每个 TiKV 实例上热点的 leader 的读取大小
- Hot read Region's peer read bytes:每个 TiKV 实例上热点的 peer 的读取大小
- Scheduler
- Scheduler is running:所有正在运行的 scheduler
- Balance leader movement:leader 移动的详细情况
- Balance Region movement:Region 移动的详细情况
- Balance leader event:balance leader 的事件数量
- Balance Region event:balance Region 的事件数量
- Balance leader scheduler:balance-leader scheduler 的状态
- Balance Region scheduler:balance-region scheduler 的状态
- Namespace checker:namespace checker 的状态
- Replica checker:replica checker 的状态
- Region merge checker:merge checker 的状态
- Operator
- Schedule operator create:新创建的不同 operator 的数量
- Schedule operator check:已检查的 operator 的数量,主要检查是否当前步骤已经执行完成,如果是,则执行下一个步骤
- Schedule operator finish:已完成的 operator 的数量
- Schedule operator timeout:已超时的 operator 的数量
- Schedule operator replaced or canceled:已取消或者被替换的 operator 的数量
- Schedule operators count by state:不同状态的 operator 的数量
- 99% Operator finish duration:已完成的 operator 中,99% 所需花费的时间
- 50% Operator finish duration:已完成的 operator 中,50% 所需花费的时间
- 99% Operator step duration:已完成的 operator 的步骤中,99% 所需花费的时间
- 50% Operator step duration:已完成的 operator 的步骤中,50% 所需花费的时间
- gRPC
- Completed commands rate:gRPC 命令的完成速率
- 99% Completed commands duration:99% 的情况下,命令的完成时间
- etcd
- Handle transactions count:etcd 的事务个数
- 99% Handle transactions duration:99% 的情况下,处理 etcd 事务所需花费的时间
- 99% WAL fsync duration:99% 的情况下,持久化 WAL 所需花费的时间,这个值通常应该小于 1s
- 99% Peer round trip time seconds:99% 的情况下,etcd 的网络延时,这个值通常应该小于 1s
- etcd disk WAL fsync rate:etcd 持久化 WAL 的速率
- Raft term:当前 Raft 的 term
- Raft committed index:最后一次 commit 的 Raft index
- Raft applied index:最后一次 apply 的 Raft index
- TiDB
- Handle requests count:TiDB 的请求数量
- Handle requests duration:每个请求所花费的时间,99% 的情况下,应该小于 100ms
- Heartbeat
- Region heartbeat report:TiKV 向 PD 发送的心跳个数
- Region heartbeat report error:TiKV 向 PD 发送的异常的心跳个数
- Region heartbeat report active:TiKV 向 PD 发送的正常的心跳个数
- Region schedule push:PD 向 TiKV 发送的调度命令的个数
- 99% Region heartbeat latency:99% 的情况下,心跳的延迟

## 图例

![PD Dashboard](../media/pd_dashboard.png)
## Cluster

- PD role:当前 PD 的角色
- Storage capacity:TiDB 集群总可用数据库空间大小
- Current storage size:TiDB 集群目前已用数据库空间大小
- Number of Regions:当前集群的 Region 总量
- Leader balance ratio:Leader 数量最多和最少节点相差的百分比,一般小于 5%,节点重启时会有比较大的波动
- Region balance ratio:Region 数量最多和最少节点相差的百分比,一般小于 5%,新增/下线节点时相差比较大
- Normal stores:处于正常状态的节点数目
- Abnormal stores:处于异常状态的节点数目,正常情况应当为 0
- Current storage usage:TiDB 集群存储空间的使用率
- Current peer count:当前集群 peer 的总量
- Metadata information:记录集群 ID,时间戳和生成的 ID
- Region label isolation level:不同 label 所在的 level 的 Region 数量
- Region health:每个 Region 的状态,通常情况下,pending 的 peer 应该少于 100,miss 的 peer 不能一直大于 0

![PD Dashboard - Cluster metrics](../media/pd-dashboard-cluster.png)

## Balance

- Store capacity:每个 TiKV 实例的总的空间大小
- Store available:每个 TiKV 实例的可用空间大小
- Store used:每个 TiKV 实例的已使用空间大小
- Size amplification:每个 TiKV 实例的空间放大比率
- Size available ratio:每个 TiKV 实例的可用空间比率
- Store leader score:每个 TiKV 实例的 leader 分数
- Store Region score:每个 TiKV 实例的 Region 分数
- Store leader size:每个 TiKV 实例上所有 leader 的大小
- Store Region size:每个 TiKV 实例上所有 Region 的大小
- Store leader count:每个 TiKV 实例上所有 leader 的数量
- Store Region count:每个 TiKV 实例上所有 Region 的数量

![PD Dashboard - Balance metrics](../media/pd-dashboard-balance.png)

## HotRegion

- Hot write Region's leader distribution:每个 TiKV 实例上是写入热点的 leader 的数量
- Hot write Region's peer distribution:每个 TiKV 实例上是写入热点的 peer 的数量
- Hot write Region's leader written bytes:每个 TiKV 实例上热点的 leader 的写入大小
- Hot write Region's peer written bytes:每个 TiKV 实例上热点的 peer 的写入大小
- Hot read Region's leader distribution:每个 TiKV 实例上是读取热点的 leader 的数量
- Hot read Region's peer distribution:每个 TiKV 实例上是读取热点的 peer 的数量
- Hot read Region's leader read bytes:每个 TiKV 实例上热点的 leader 的读取大小
- Hot read Region's peer read bytes:每个 TiKV 实例上热点的 peer 的读取大小

![PD Dashboard - HotRegion metrics](../media/pd-dashboard-hot-region.png)

## Scheduler

- Scheduler is running:所有正在运行的 scheduler
- Balance leader movement:leader 移动的详细情况
- Balance Region movement:Region 移动的详细情况
- Balance leader event:balance leader 的事件数量
- Balance Region event:balance Region 的事件数量
- Balance leader scheduler:balance-leader scheduler 的状态
- Balance Region scheduler:balance-region scheduler 的状态
- Namespace checker:namespace checker 的状态
- Replica checker:replica checker 的状态
- Region merge checker:merge checker 的状态

![PD Dashboard - Scheduler metrics](../media/pd-dashboard-scheduler.png)

## Operator

- Schedule operator create:新创建的不同 operator 的数量
- Schedule operator check:已检查的 operator 的数量,主要检查是否当前步骤已经执行完成,如果是,则执行下一个步骤
- Schedule operator finish:已完成的 operator 的数量
- Schedule operator timeout:已超时的 operator 的数量
- Schedule operator replaced or canceled:已取消或者被替换的 operator 的数量
- Schedule operators count by state:不同状态的 operator 的数量
- 99% Operator finish duration:已完成的 operator 中,99% 所需花费的时间
- 50% Operator finish duration:已完成的 operator 中,50% 所需花费的时间
- 99% Operator step duration:已完成的 operator 的步骤中,99% 所需花费的时间
- 50% Operator step duration:已完成的 operator 的步骤中,50% 所需花费的时间

![PD Dashboard - Operator metrics](../media/pd-dashboard-operator.png)

## gRPC

- Completed commands rate:gRPC 命令的完成速率
- 99% Completed commands duration:99% 的情况下,命令的完成时间

![PD Dashboard - gRPC metrics](../media/pd-dashboard-grpc.png)

## etcd

- Handle transactions count:etcd 的事务个数
- 99% Handle transactions duration:99% 的情况下,处理 etcd 事务所需花费的时间
- 99% WAL fsync duration:99% 的情况下,持久化 WAL 所需花费的时间,这个值通常应该小于 1s
- 99% Peer round trip time seconds:99% 的情况下,etcd 的网络延时,这个值通常应该小于 1s
- etcd disk WAL fsync rate:etcd 持久化 WAL 的速率
- Raft term:当前 Raft 的 term
- Raft committed index:最后一次 commit 的 Raft index
- Raft applied index:最后一次 apply 的 Raft index

![PD Dashboard - etcd metrics](../media/pd-dashboard-etcd.png)

## TiDB

- Handle requests count:TiDB 的请求数量
- Handle requests duration:每个请求所花费的时间,99% 的情况下,应该小于 100ms

![PD Dashboard - TiDB metrics](../media/pd-dashboard-tidb.png)

## Heartbeat

- Region heartbeat report:TiKV 向 PD 发送的心跳个数
- Region heartbeat report error:TiKV 向 PD 发送的异常的心跳个数
- Region heartbeat report active:TiKV 向 PD 发送的正常的心跳个数
- Region schedule push:PD 向 TiKV 发送的调度命令的个数
- 99% Region heartbeat latency:99% 的情况下,心跳的延迟

![PD Dashboard - Heartbeat metrics](../media/pd-dashboard-heartbeat.png)
Loading

0 comments on commit c4e4660

Please sign in to comment.