Skip to content

Instantly share code, notes, and snippets.

@dubcl
Created August 22, 2018 23:21
Show Gist options
  • Save dubcl/4b77584a839962859c93b4fc036f8cb0 to your computer and use it in GitHub Desktop.
Save dubcl/4b77584a839962859c93b4fc036f8cb0 to your computer and use it in GitHub Desktop.
Kafka enable JMX and set java heap
export JMX_PORT=${JMX_PORT:-9999}
export KAFKA_JMX_OPTS="-Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.rmi.port=$JMX_PORT -Dcom.sun.management.jmxremote.port=$JMX_PORT -Dcom.sun.management.jmxremote=true -Djava.rmi.server.hostname=<IP ADDRESS> -Djava.net.preferIPv4Stack=true"
export KAFKA_HEAP_OPTS="-Xmx6G -Xms6G"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment