Bringing together the Apache Cassandra experts from the community and DataStax.

Want to learn? Have a question? Want to share your expertise? You are in the right place!

Not sure where to begin? Getting Started

 

question

nagasree963_193876 avatar image
nagasree963_193876 asked nagasree963_193876 commented

Which port is configured for JMX with the cass-operator?

How to configure to enable jmx port in cr.yaml (exmple-cassdc-minimal.yaml). I deployed by following the below one:

https://github.com/datastax/cass-operator

I want to enable jmx port for metrics. Which port it is?

cass-operator
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

john.sanda_194109 avatar image
john.sanda_194109 answered nagasree963_193876 commented

Hi @nagasree963_193876

You are correct in that remote JMX is disabled. In K8ssandra we make some changes to the CassandraDatacenter spec to enable it. You can look here to see what we do.

We really leverage the podTemplateSpec property of CassandraDatacenter to make it all work.

I recently wrote this blob post talking briefly about the podTemplateSpec property. I hope to have a follow up post within the next few days that discusses exactly how the podTemplateSpec property is used to enable remote JMX.

Stay tuned and definitely check out http://k8ssandra.io/ :)

1 comment Share
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Is it possible to enable remote JMX in cassoperator 1.1.0? I am using below config to enable.. But still I can see that JMX is disabled. How to pass config to enable JMX?

```

jvm-options:

# Set the database to use 2 GB of Java heap

initial_heap_size: "800M"

max_heap_size: "800M"

additional-jvm-opts:

# As the database comes up for the first time, set system keyspaces to RF=3

# - "-Dcassandra.system_distributed_replication_dc_names=dc1"

# - "-Dcassandra.system_distributed_replication_per_dc=3"

jmx-remote-ssl-opts:

- "-Dcom.sun.management.jmxremote.authenticate=true"

```



0 Likes 0 ·
Erick Ramirez avatar image
Erick Ramirez answered nagasree963_193876 commented

The cass-operator uses the default JMX port 7199.

As a side note, I wanted to bring K8ssandra to your attention in case you didn't know about it yet. It still uses the cass-operator under the hood but is packaged with the following:

  • Reaper for automated repairs
  • Medusa for backups and restores
  • Metrics Collector for monitoring with Prometheus + Grafana
  • Traefik templates for k8s cluster ingress

Cheers!

3 comments Share
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Thanks Erick Ramirez . My doubt was do we need to enable that jmx port or by default, it exposes jmx port 7199

0 Likes 0 ·

I checked that jmx remote port is set to false. I was trying to pass the below config in cassandra_cr.yaml:

```

jvm-options:

# Set the database to use 2 GB of Java heap

initial_heap_size: "800M"

max_heap_size: "800M"

- "-Dcom.sun.management.jmxremote.authenticate=true"

```

Is that correct config or need to change configurations?

0 Likes 0 ·

Please confirm one thing, Is it possible to enable jmx metrics in cass-operator :1.1.0 !!


0 Likes 0 ·