mysqld_exporter采集metrics,出现nodata

最近安装Prometheus+grafana做服务器监控,引用grafana官网的模板,发现有两个图表没有数据
如图
在这里插入图片描述
经过一系列排错,包括检查取值公式,检查公式内引用变量,换exporter版本。。。
最后得到结论:那是因为mysqld_exporter启动参数少东西了
具体参数以及意义如下

启动参数MySQL版本参数含义
collect.auto_increment.columns5.1 +从information_schema收集auto_increment列和最大值。
collect.binlog_size5.1+收集所有已注册的Binlog文件的当前大小
collect.engine_innodb_status5.1+通过SHOW ENGINE INNODB STATUS收集数据
collect.engine_tokudb_status5.6+通过SHOW ENGINE TOKUDB STATUS.收集数据
collect.global_status5.1+通过SHOW GLOBAL STATUS 收集数据(默认开启)
collect.global_variables5.1+通过SHOW GLOBAL VARIABLES收集数据(默认开启)
collect.info_schema.clientstats5.5+如果被监控的MySQL使用userstat = 1运行,则此参数需要设置为1以收集客户端统计信息
collect.info_schema.innodb_metrics5.6+从information_schema.innodb_metrics收集数据。
collect.info_schema.innodb_tablespaces5.7+从information_schema.innodb_sys_tablespaces收集数据。
collect.info_schema.innodb_cmp5.5+从information_schema.innodb_cmp收集InnoDB压缩表指标。
collect.info_schema.innodb_cmpmem5.5+从information_schema.innodb_cmpmem收集InnoDB缓冲池。
collect.info_schema.processlist5.1+从information_schema.processlist收集线程状态计数。
collect.info_schema.processlist.min_time5.1+线程状态停留多长时间会被统计。(默认值:0)
collect.info_schema.query_response_time5.5+如果query_response_time_stats为ON,则收集查询响应时间。
collect.info_schema.replica_host5.6+从information_schema.replica_host_status收集数据。
collect.info_schema.tables5.1+从information_schema.tables中收集数据。
collect.info_schema.tables.databases5.1+收集表统计信息的数据库列表,或*全部为’的数据库
collect.info_schema.tablestats5.1+如果被监控的MySQL使用userstat = 1运行,则设置为true以收集表统计信息。
collect.info_schema.schemastats5.1+如果被监控的MySQL使用userstat = 1运行,则设置为true以收集架构统计信息
collect.info_schema.userstats5.1+如果被监控的MySQL使用userstat = 1运行,则设置为true以收集用户统计信息。
collect.perf_schema.eventsstatements5.6+从performance_schema.events_statements_summary_by_digest收集数据。
collect.perf_schema.eventsstatements.digest_text_limit5.6+规范化语句文本的最大长度。(默认值:120)
collect.perf_schema.eventsstatements.limit5.6+通过响应时间限制事件语句摘要的数量。(预设值:250)
collect.perf_schema.eventsstatements.timelimit5.6+限制“ last_seen”事件语句的年龄(以秒为单位)。(预设值:86400)
collect.perf_schema.eventsstatementssum5.7+从Performance_schema.events_statements_summary_by_digest汇总中收集指标。
collect.perf_schema.eventswaits5.5+从Performance_schema.events_waits_summary_global_by_event_name收集指标。
collect.perf_schema.file_events5.6+从Performance_schema.file_summary_by_event_name收集指标。
collect.perf_schema.file_instances5.5+从performance_schema.file_summary_by_instance收集指标。
collect.perf_schema.indexiowaits5.6+从performance_schema.table_io_waits_summary_by_index_usage收集指标。
collect.perf_schema.tableiowaits5.6+从Performance_schema.table_io_waits_summary_by_table收集指标。
collect.perf_schema.tablelocks5.6+从Performance_schema.table_lock_waits_summary_by_table收集指标。
collect.perf_schema.replication_group_members5.7+从Performance_schema.replication_group_members收集指标。
collect.perf_schema.replication_group_member_stats5.7 +从Performance_schema.replication_group_member_stats收集指标。
collect.perf_schema.replication_applier_status_by_worker5.7+从performance_schema.replication_applier_status_by_worker收集指标。
collect.slave_status5.1+从SHOW SLAVE STATUS收集(默认情况下启用)
collect.slave_hosts5.1+从SHOW SLAVE HOSTS收集
collect.heartbeat5.1+从心跳中收集。
collect.heartbeat.database5.1+从中收集心跳数据的数据库。(默认值:心跳)
collect.heartbeat.table5.1+从何处收集心跳数据的表。(默认值:心跳)
  • 0
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值