Files
hertzbeat/home/docs/help/postgresql.md
tomsun28 820cb7a3e5 [manager,home]添加sqlserver关联文档,fix connection指标入库tdengine失败 (#41)
* [manager,home]添加sqlserver关联文档,fix connection指标入库tdengine失败

* [docs]文档更新
2022-03-20 13:27:13 +08:00

58 lines
2.9 KiB
Markdown
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
id: postgresql
title: 监控PostgreSQL数据库监控
sidebar_label: PostgreSQL数据库
---
> 对PostgreSQL数据库的通用性能指标进行采集监控。支持PostgreSQL 10+。
### 配置参数
| 参数名称 | 参数帮助描述 |
| ----------- | ----------- |
| 监控Host | 被监控的对端IPV4IPV6或域名。注意⚠不带协议头(eg: https://, http://)。 |
| 监控名称 | 标识此监控的名称,名称需要保证唯一性。 |
| 端口 | 数据库对外提供的端口默认为5432。 |
| 查询超时时间 | 设置SQL查询未响应数据时的超时时间单位ms毫秒默认3000毫秒。 |
| 数据库名称 | 数据库实例名称,可选。 |
| 用户名 | 数据库连接用户名,可选 |
| 密码 | 数据库连接密码,可选 |
| URL | 数据库连接URL可选若配置则URL里面的数据库名称用户名密码等参数会覆盖上面配置的参数 |
| 采集间隔 | 监控周期性采集数据间隔时间单位秒可设置的最小间隔为10秒 |
| 是否探测 | 新增监控前是否先探测检查监控可用性,探测成功才会继续新增修改操作 |
| 描述备注 | 更多标识和描述此监控的备注信息,用户可以在这里备注信息 |
### 采集指标
#### 指标集合basic
| 指标名称 | 指标单位 | 指标帮助描述 |
| ----------- | ----------- | ----------- |
| server_version | 无 | 数据库服务器的版本号 |
| port | 无 | 数据库服务器端暴露服务端口 |
| server_encoding | 无 | 数据库服务器端的字符集编码 |
| data_directory | 无 | 数据库存储数据盘地址 |
| max_connections | 连接数 | 数据库最大连接数 |
#### 指标集合state
| 指标名称 | 指标单位 | 指标帮助描述 |
| ----------- | ----------- | ----------- |
| name | 无 | 数据库名称或share-object为共享对象。 |
| conflicts | 次数 | 由于与恢复冲突而在这个数据库中被取消的查询的数目 |
| deadlocks | 个数 | 在这个数据库中被检测到的死锁数 |
| blks_read | 次数 | 在这个数据库中被读取的磁盘块的数量 |
| blks_hit | 次数 | 磁盘块被发现已经在缓冲区中的次数,这样不需要一次读取(这只包括 PostgreSQL 缓冲区中的命中,而不包括在操作系统文件系统缓冲区中的命中) |
| blk_read_time | ms | 在这个数据库中后端花费在读取数据文件块的时间 |
| blk_write_time | ms | 在这个数据库中后端花费在写数据文件块的时间 |
| stats_reset | 无 | 这些统计信息上次被重置的时间 |
#### 指标集合activity
| 指标名称 | 指标单位 | 指标帮助描述 |
| ----------- | ----------- | ----------- |
| running | 连接数 | 当前客户端连接数 |