oliver006/redis_exporter

redis_exporter is not supporting multiple '-redis.addr' entries

Udayendu opened this issue · 5 comments

Describe the problem
If 5 redis processes running with their own ports starting from 7001 to 7005 and when I am passing the multiple redis address entries, redis_exporter is only listening to the last entry of the address. Eg:

/usr/bin/redis_exporter -web.listen-address  localhost:9997 -redis.addr redis://localhost:7001 -redis.addr redis://localhost:7002  -redis.addr redis://localhost:7003  -redis.addr redis://localhost:7004  -redis.addr redis://localhost:7005

If I am using the above command, redis_exporter is only showing the data for process running on 7005 port.

What version of redis_exporter are you running?

INFO[0000] Redis Metrics Exporter v1.56.0    build date: 2023-12-28-04:40:03    sha1: 8b2b2e9c48844500ebcf449a864dc152b14998cb    Go: go1.20.10    GOOS: linux    GOARCH: amd64

Running the exporter

/usr/bin/redis_exporter -web.listen-address :9997 -redis.addr redis://localhost:7001 -redis.addr redis://localhost:7002  -redis.addr redis://localhost:7003  -redis.addr redis://localhost:7004  -redis.addr redis://localhost:7005

Environment

  • redis has been installed in Debian 12
  • redis_exporter is used directly inside the Debian 12 vm under /usr/bin/redis_exporter path.

Expected behavior
It should allow the metrics from all the redis ports.

Additional context
For a single port, it's working perfectly but not able to handle the multiple ports.

Have a look at the documentation on how to scrape multiple Redis instances with one exporter.

Thanks @oliver006 . After using /usr/bin/redis_exporter -web.listen-address localhost:9997, I am able to start the exporter and using scrape able to call multiple redis instances.