tidb监控突然没有数据问题

栏目: 服务器 · 发布时间: 7年前

内容简介:tidb的grafana界面突然没有数据,看后台alertmanager日志level=error ts=2018-07-19T09:39:54.470233355Z caller=dispatch.go:266 component=dispatcher msg="Notify for alerts failed" num_alerts=1 err="dial tcp 127.0.0.1:25: getsockopt: connection refused"level=error ts=2018-07-1

tidb的grafana界面突然没有数据,看后台alertmanager日志

level=error ts=2018-07-19T09:39:54.470233355Z caller=dispatch.go:266 component=dispatcher msg="Notify for alerts failed" num_alerts=1 err="dial tcp 127.0.0.1:25: getsockopt: connection refused"

level=error ts=2018-07-19T09:39:54.470337114Z caller=notify.go:303 component=dispatcher msg="Error on notify" err="dial tcp 127.0.0.1:25: getsockopt: connection refused"

level=error ts=2018-07-19T09:39:54.470342259Z caller=notify.go:303 component=dispatcher msg="Error on notify" err="dial tcp 127.0.0.1:25: getsockopt: connection refused"

level=error ts=2018-07-19T09:39:54.470352018Z caller=dispatch.go:266 component=dispatcher msg="Notify for alerts failed" num_alerts=1 err="dial tcp 127.0.0.1:25: getsockopt: connection refused"

level=error ts=2018-07-19T09:39:54.470356533Z caller=dispatch.go:266 component=dispatcher msg="Notify for alerts failed" num_alerts=1 err="dial tcp 127.0.0.1:25: getsockopt: connection refused"

start_grafana_collector.sh 只是个辅助插件,用老导出 metrics PDF

1、去grafana的服务器pd-1上,重启下grafana服务,重启脚本在/data0/tidb/deploy/scripts目录下

sh stop_grafana_collector.sh

sh stop_grafana.sh

sh start_grafana_collector.sh

sh start_grafana.sh

看了下,还是没有监控数据,按照惯例,监控没有数据量,可以去检查 push gateway 和 Prometheus ,重启下这2个服务

sh stop_prometheus.sh

sh stop_pushgateway.sh

start stop_prometheus.sh

start stop_pushgateway.sh

监控上,还是没有记录

2、查看grafana的架构

tidb监控突然没有数据问题

Grafana有2个重要点,一个是prometheus,一个是pushgateway,从这2方面查下问题

3、排查问题

1、查看pushgateway网页

http://st3-goods-pd-1.prod.yiran.com:9091/# 查看节点最新更新时间

点开其中一个,看下 lastupdate 时间

lastupdate时间是最新的记录,然后看下gateway的日志

tidb监控突然没有数据问题

2、查看先看下 Prometheus网页

http://st3-goods-pd-1.prod.yiran.com:9090 查看所有节点是否UP状态

所有节点都是Up状态

然后输入参数,查看下数据

tidb监控突然没有数据问题

其中,输入sum(rate(tidb_server_query_total[1m])) by (result),查下没有数据记录;输入node_disk_io_time_ms,查下有数据记录,而node_disk_io_time_ms在grafana上也有监控图记录;这个表示:那就是 tidb  pd  tikv  到 push gateway 得没数据了,node export 是 ok 得

3、重置prometheus参数

tidb监控突然没有数据问题

/data0/tidb/deploy/conf/prometheus.yml,之前默认是3,修改成如下值

scrape_configs

scrape_interval: 15s

scrape_timeout: 10s

evaluation_interval: 15s

修改后,重启promecheus服务

sh stop_prometheus.sh

sh start_prometheus.sh

之后grafana界面就有数据显示了。


以上所述就是小编给大家介绍的《tidb监控突然没有数据问题》,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对 码农网 的支持!

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Essential C++中文版

Essential C++中文版

李普曼 (Stanley B.Lippman) / 侯捷 / 电子工业出版社 / 2013-8-1 / CNY 65.00

本书以四个面向来表现C++的本质:procedural(面向过程的)、generic(泛型的)、object-based(基于对象的)、objectoriented(面向对象的)。全书围绕一系列逐渐繁复的程序问题,以及用以解决这些问题的语言特性来组织。循此方式,你将不只学到C++的功能和结构,也可学到它们的设计目的和基本原理。 本书适合那些已经开始从事软件设计,又抽不出太多时间学习新技术的程......一起来看看 《Essential C++中文版》 这本书的介绍吧!

随机密码生成器
随机密码生成器

多种字符组合密码

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具

HSV CMYK 转换工具
HSV CMYK 转换工具

HSV CMYK互换工具