docker+influxdb+grafana+jmeter性能监控

时间:2020-02-26 13:57:59   收藏:0   阅读:102

influxdb

docker参考:https://hub.docker.com/_/influxdb

github地址:https://github.com/influxdata/influxdb

doc地址:https://v2.docs.influxdata.com/v2.0/

 其他解释参考:https://www.jianshu.com/p/1be8b7273b89

 一些概念:

database相当于mysql中的database

measurement相当于mysql中的表

point相当于mysql中的行

tag相当于mysql中的索引,只支持字符串类型

field相当于mysql中的列,支持多种类型

retention policy保存策略,这是influxdb特有的属性,rp指定数据在influxdb中的保存时间,时间已过,influxdb会自动清除数据。

continuous queries 特色功能之一,相当于定时任务

注意:influxdb不支持修改语句,虽然有删除语句,但是不建议使用。

  

通过宿主机,给容器创建数据库:

curl -G http://localhost:8086/query --data-urlencode "q=CREATE DATABASE jmeter_yin"

  

 

 

grafana

docker地址:

doc地址:http://docs.grafana.org/features/datasources/influxdb/

 

docker run --name=mall-grafana -p 8083:3000 -d grafana/grafana

  

登录grafana:

http://172.31.124.11:8083/

默认账密 admin admin

添加influxdb 数据库,并编辑显示的表单内容

官方模板地址:https://grafana.com/dashboards?dataSource=influxdb

参考:https://testerhome.com/topics/16548

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!