如何将Gatling性能结果推送到EC2 Grafana/InfluxDB实例


我启动了一个t2.micro Ubuntu18.04 EC2实例,在这个EC2实例中,我手动安装了Grafana和InfluxDB。Grafana和InfluxDB都已成功安装,没有错误,但现在我期望的是,当我在windows本地运行Gatling测试时,结果应该会被实时推送到InfluxDB,并最终推送到Grafana。

下面是我的Gatling.conf设置摘录

data {
 writers = [console, file, graphite]      # The list of DataWriters to which Gatling write simulation data (currently supported : console, file, graphite, jdbc)
 console {
  #light = false                # When set to true, displays a light version without detailed request stats
  #writePeriod = 5              # Write interval, in seconds
   }

 graphite {
  light = false              # only send the all* stats
  host = "http://ec2-54-67-97-86.us-west-1.compute.amazonaws.com"         # The host where the Carbon server is located
  port = 2003                # The port to which the Carbon server listens to (2003 is default for plaintext, 2004 is default for pickle)
  protocol = "tcp"           # The protocol used to send data to Carbon (currently supported : "tcp", "udp")
  rootPathPrefix = "gatling" # The common prefix of all metrics sent to Graphite
  bufferSize = 8192          # GraphiteDataWriter's internal data buffer size, in bytes
  writeInterval = 1          # GraphiteDataWriter's write interval, in seconds
}

问题是当我从本地运行我的Gatling测试时,我在influx实例中看不到数据

ubuntu@ip-172-31-9-16:~$ influx -host ec2-54-67-97-86.us-west-1.compute.amazonaws.com                                                    Connected to http://ec2-54-67-97-86.us-west-1.compute.amazonaws.com:8086 version 1.7.7
InfluxDB shell version: 1.7.7
> show databases
name: databases
name
----
_internal
gatling
graphite
> use graphite
Using database graphite
> show series
key
---
X-Grafana-Org-Id:

有没有人能帮我调试一下,这就是为什么influx DB没有收到数据的原因

转载请注明出处:http://www.runhoujixie.com/article/20230526/1796759.html