Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Solr, Adding a Javaagent

avatar
Contributor

Hi,

Probably a simple question. I am attempting to run a javaagent in the form of the jmx metrics exporter to prometheus jar file. I can kick off the java agent manually on each server but it would be preferred if I could add the command to the Solr Env file so Ambari manages start/stop of it with Solr.

Here is the working syntax I use when starting Solr not managed by Ambari. I am not sure where to add this on Solr's Ambari configuration as I have not been successful in getting it to work yet.

-a "-javaagent:/incubate/solr_jmx/solr-7.1.0/jmx/jmx_prometheus_javaagent-0.1.0.jar=7500:/incubate/solr_jmx/solr-7.1.0/jmx/config.yml"

Any help is appreciated!

1 ACCEPTED SOLUTION

avatar
Contributor
hide-solution

This problem has been solved!

Want to get a detailed solution you have to login/registered on the community

Register/Login
2 REPLIES 2

avatar
Rising Star

In Ambari under Solr there is a box for environment stuff. I don't have Ambari in front of me right now but you should be able to add a line like so:

SOLR_OPTS="$SOLR_OPTS -javaagent...."

avatar
Contributor
hide-solution

This problem has been solved!

Want to get a detailed solution you have to login/registered on the community

Register/Login