跳转至

TDengine

·


TDengine 是一款高性能、分布式、支持 SQL 的时序数据库 (Database)。在开通采集器之前请先熟悉 TDengine 基本概念

TDengine 采集器需要的连接 taos_adapter 才可以正常工作,taosAdapter 从 TDengine v2.4.0.0 版本开始成为 TDengine 服务端软件 的一部分,本文主要是指标集的详细介绍。

配置

采集器配置

进入 DataKit 安装目录下的 conf.d/samples 目录,复制 tdengine.conf.sample 并命名为 tdengine.conf。示例如下:

[[inputs.tdengine]]
  ## adapter restApi Addr, example: http://taosadapter.test.com  (Required)
  adapter_endpoint = "http://<FQND>:6041"
  user = "<userName>"
  password = "<pw>"

  ## log_files: TdEngine log file path or dirName (optional).
  ## log_files = ["tdengine_log_path.log"]
  ## pipeline = "tdengine.p"

  ## Set true to enable election
  election = true

  ## add tag (optional)
  [inputs.tdengine.tags]
  ## Different clusters can be distinguished by tag. Such as testing,product,local ,default is 'testing'
  # cluster_name = "testing"
  # some_tag = "some_value"
  # more_tag = "some_other_value"

配置好后,重启 DataKit 即可。

目前可以通过 ConfigMap 方式注入采集器配置来开启采集器。

Info
  • 连接 taoAdapter 之前请先确定端口是开放的。并且连接用户需要有 read 权限。
  • 若仍连接失败,请参考此处

指标

tdengine

TDengine cluster, database, data node, request, and taosAdapter metrics collected from system log tables and show commands.

Tags & Fields Description
client_ip
(tag)
Client IP
cluster_name
(tag)
Cluster name
database_name
(tag)
Database name
dnode_ep
(tag)
Data node name, generally equivalent to end_point
end_point
(tag)
Remote address name, the general naming rule is (host:port)
endpoint
(tag)
taosAdapter endpoint
first_ep
(tag)
First endpoint
host
(tag)
Host name
offline_reason
(tag)
Reason the data node is offline
role
(tag)
Management node role
role_time
(tag)
Management node role start time
status
(tag)
Data node status
status_code
(tag)
HTTP response status code
version
(tag)
Version
vgroup_id
(tag)
VGroup ID
client_ip_count Client IP request statistics
Type: float | (gauge)
Unit: count
Tagged by: client_ip
cpu_cores Total number of CPU cores per data node
Type: float | (gauge)
Unit: count
Tagged by: dnode_ep
cpu_engine CPU usage per data node
Type: float | (gauge)
Unit: percent,percent
Tagged by: dnode_ep
cpu_percent Adapter occupies CPU usage
Type: float | (gauge)
Unit: percent,percent
Tagged by: endpoint
cpu_system CPU system usage of data nodes
Type: float | (gauge)
Unit: count
Tagged by: dnode_ep
database_count Total number of databases
Type: float | (gauge)
Unit: count
disk_percent Data node disk usage percentage
Type: float | (gauge)
Unit: percent,percent
Tagged by: dnode_ep
disk_total Total disk size of data nodes
Type: float | (gauge)
Unit: digital,GB
Tagged by: dnode_ep
disk_used Disk usage of data nodes
Type: float | (gauge)
Unit: digital,GB
Tagged by: dnode_ep
dnodes_alive Total number of dnodes in ready state
Type: float | (gauge)
Unit: count
dnodes_total Total number of dnodes(data nodes) in cluster
Type: float | (gauge)
Unit: count
expire_time Time until grants expire in seconds
Type: int | (gauge)
Unit: time,s
id TDengine node ID
Type: float | (gauge)
Unit: N/A
Tagged by: end_point, offline_reason, role, role_time, status
io_read_taosd Average data size of IO reads per second
Type: float | (gauge)
Unit: digital,MB
Tagged by: dnode_ep
io_write_taosd Average data size of IO writes per second
Type: float | (gauge)
Unit: digital,MB
Tagged by: dnode_ep
master_uptime Seconds of master's uptime
Type: float | (gauge)
Unit: time,s
Tagged by: first_ep, version
mem_engine Memory usage of tdengine
Type: float | (gauge)
Unit: digital,MB
Tagged by: dnode_ep
mem_engine_percent taosd memory usage percentage
Type: float | (gauge)
Unit: percent,percent
Tagged by: dnode_ep
mem_percent Adapter memory usage
Type: float | (gauge)
Unit: percent,percent
Tagged by: endpoint
mem_system Available memory on the server
Type: float | (gauge)
Unit: digital,MB
Tagged by: dnode_ep
mem_total Total memory of server
Type: float | (gauge)
Unit: digital,GB
Tagged by: dnode_ep
mnodes_alive Total number of mnodes in ready state
Type: float | (gauge)
Unit: count
mnodes_total Total number of mnodes(management nodes) in cluster
Type: float | (gauge)
Unit: count
net_in IO rate of the ingress network
Type: float | (gauge)
Unit: digital,KB
Tagged by: dnode_ep
net_out IO rate of egress network
Type: float | (gauge)
Unit: digital,KB
Tagged by: dnode_ep
req_http Total number of requests via HTTP
Type: float | (gauge)
Unit: count
req_http_rate HTTP request rate
Type: float | (gauge)
Unit: count
req_insert_batch_rate Number of batch insertions divided by monitor interval
Type: float | (gauge)
Unit: count
Tagged by: dnode_ep
req_insert_rate Number of insert queries received per dnode divided by monitor interval
Type: float | (gauge)
Unit: count
Tagged by: dnode_ep
req_select Number of select queries received per dnode
Type: float | (gauge)
Unit: count
Tagged by: dnode_ep
req_select_rate Number of select queries received per dnode divided by monitor interval
Type: float | (gauge)
Unit: count
Tagged by: dnode_ep
request_in_flight Number of requests being sorted
Type: float | (gauge)
Unit: count
status_code Status code returned by the request
Type: float | (gauge)
Unit: count
table_count Total number of tables in the database
Type: float | (gauge)
Unit: count
tables_count Number of tables per vgroup
Type: float | (gauge)
Unit: count
Tagged by: database_name
timeseries_total Total time series
Type: float | (gauge)
Unit: count
timeseries_used Time series used
Type: float | (gauge)
Unit: count
total_req_count Total adapter requests
Type: float | (gauge)
Unit: count
Tagged by: endpoint, status_code
uptime Data node uptime in seconds
Type: float | (gauge)
Unit: time,s
Tagged by: dnode_ep
vgroups_alive Total number of vgroups in ready state
Type: float | (gauge)
Unit: count
vgroups_total Total number of vgroups in cluster
Type: float | (gauge)
Unit: count
vnodes The number of virtual node groups contained in a single data node
Type: float | (gauge)
Unit: count
Tagged by: end_point, offline_reason, status
vnodes_alive Total number of vnode in ready state
Type: float | (gauge)
Unit: count
vnodes_num Total number of virtual nodes per data node
Type: float | (gauge)
Unit: count
Tagged by: dnode_ep
vnodes_total Total number of vnode in cluster
Type: float | (gauge)
Unit: count
  • 数据库中有些表中没有 ts 字段,DataKit 会使用当前采集的时间。

文档评价

文档内容是否对您有帮助? ×