sensu-plugins / sensu-plugins-redis

This plugin provides native Redis instrumentation for monitoring and metrics collection, including: service health, database connectivity, replication status, `INFO` metrics, key counts, list lengths, and more.
http://sensu-plugins.io
MIT License
12 stars 44 forks source link

metrics-redis-graphite.rb does not send metrics #38

Closed phumpal closed 7 years ago

phumpal commented 7 years ago

metrics-redis-graphite.rb does not send metrics to graphite.

Other metrics on the same server are successfully sent to graphite. These include cpu, disk, memory, network, and custom application metrics.

VPC NACL and security group rules are open.

Command is successful from the cli

metrics-redis-graphite.rb
staging-redis-cache-1.redis.uptime_in_seconds 994293 1499816064
staging-redis-cache-1.redis.uptime_in_days 11 1499816064
staging-redis-cache-1.redis.hz 10 1499816064
staging-redis-cache-1.redis.lru_clock 6643840 1499816064
staging-redis-cache-1.redis.connected_clients 61 1499816064
...

Output at sensu-client startup

{
   "timestamp":"2017-07-11T23:15:07.849265+0000",
   "level":"warn",
   "message":"config file applied changes",
   "file":"/etc/sensu/conf.d/checks/redis_metrics.json",
   "changes":{
      "checks":{
         "redis_metrics":[
            null,
            {
               "command":"metrics-redis-graphite.rb",
               "handlers":[
                  "relay"
               ],
               "subscribers":[
                  "all"
               ],
               "type":"metric",
               "interval":10
            }
         ]
      }
   }
}

Metrics config

{
  "checks": {
    "redis_metrics": {
      "command": "metrics-redis-graphite.rb",
      "handlers": [
        "relay"
      ],
      "subscribers": [
        "all"
      ],
      "type": "metric",
      "interval": 10
    }
  }
}

Relay config

  "handlers": {
    "relay": {
      "type": "tcp",
      "socket": {
          "host": "172.16.7.89",
          "port": 2003
      },
      "command": "/etc/sensu/handlers/relay.rb",
      "mutator": "only_check_output"
    }
  }

Runtime environment

I was curious if someone can verify metrics-redis-graphite.rb is working?

It doesn't seem to work in my local or staging environments.

phumpal commented 7 years ago

Disregard. Oversight on my behalf; per client check needs "standalone": true