Skip to content

Cassandra

Auto-Detection
Built-in Metrics

Bleemeo monitors Cassandra through automatic service detection and JMX metrics collection for cluster performance.

Glouton automatically detects Cassandra instances running on the system.

To enable metrics gathering, the Bleemeo agent must be installed with JMX enabled. See Java Metrics for setup details.

Cassandra must also expose JMX over a TCP port:

  • Docker: Add environment variable JVM_OPTS=-Dcassandra.jmx.remote.port=7199.
  • Native package: No additional configuration is needed. Cassandra exposes JMX on port 7199 on localhost by default.
  • Other setups: Add -Dcom.sun.management.jmxremote.port=7199 -Dcom.sun.management.jmxremote.authenticate=false to the JVM options.

If auto-detected parameters are incorrect, you can override them manually.

Terminal window
sudo tee /etc/glouton/conf.d/99-cassandra.conf > /dev/null << 'EOF'
service:
# For a Cassandra running outside a container
- type: "cassandra"
address: "127.0.0.1"
port: 9042
jmx_port: 7199
jmx_username: "cassandra" # by default, no authentication is done
jmx_password: "cassandra"
# For an additional Cassandra running outside a container
- type: "cassandra"
instance: "NAME_ASSOCIATED_WITH_YOUR_ADDITIONAL_SERVICE"
address: "127.0.0.1"
port: 9043
jmx_port: 7200
jmx_username: "cassandra" # by default, no authentication is done
jmx_password: "cassandra"
# For a Cassandra running in a Docker container
- type: "cassandra"
instance: "CONTAINER_NAME"
address: "172.17.0.2"
port: 9042
jmx_port: 7199
jmx_username: "cassandra" # by default, no authentication is done
jmx_password: "cassandra"
EOF

Glouton automatically detects configuration changes.

Metric Description
service_status Status of Cassandra
cassandra_bloom_filter_false_ratio Bloom filter false positive ratio in percent
cassandra_jvm_gc Number of garbage collections per second
cassandra_jvm_gc_utilization Garbage collection utilization in percent
cassandra_jvm_heap_used Heap memory used in bytes
cassandra_jvm_non_heap_used Non-heap memory used in bytes
cassandra_read_requests Number of read requests per second
cassandra_read_time Average time of read requests in seconds
cassandra_sstable Number of SSTables
cassandra_write_requests Number of write requests per second
cassandra_write_time Average time of write requests in seconds

Bleemeo supports detailed monitoring of specific Cassandra tables. To enable this, add detailed_items to your service configuration.

Terminal window
sudo tee /etc/glouton/conf.d/99-cassandra.conf > /dev/null << 'EOF'
service:
# For a Cassandra running outside a container
- type: "cassandra"
detailed_items:
- "keyspace1.table1"
- "keyspace2.table2"
# For a Cassandra running in a Docker container
- type: "cassandra"
instance: "CONTAINER_NAME"
detailed_items:
- "keyspace1.table1"
- "keyspace2.table2"
EOF

The following per-table metrics are gathered:

Metric Description
cassandra_bloom_filter_false_ratio Bloom filter false positive ratio in percent
cassandra_read_requests Number of read requests per second
cassandra_read_time Average time of read requests in seconds
cassandra_sstable Number of SSTables
cassandra_write_requests Number of write requests per second
cassandra_write_time Average time of write requests in seconds