Hello Everyone , Have started to use jmx prometheus agent for linux .. Application server tomcat jmx version : 0.14.0
*setenv.sh * export PROJECT="test" export CATALINA_HOME="/apps/install/jws-tomcat9/current" export CATALINA_BASE="/data/tomcat_test/tomcat" export CATALINA_PID="/data/tomcat_test/tomcat/logs/tomcat_test.pid" export JAVA_HOME="/apps/install/java/jdk8_current" export TOMCAT_USER="test" trying to access : curl http://localhost:9080/metrics -k -v --noproxy "*" but unable to connect config: --- lowercaseOutputLabelNames: true lowercaseOutputName: true whitelistObjectNames: ["Tomcat:*","Catalina:*"] rules: - pattern: '.*<type=GlobalRequestProcessor, name=\"(\w+-\w+)-(\d+)\"><>(\w+):' name: tomcat_$3_total labels: port: "$2" protocol: "$1" help: Tomcat global $3 type: COUNTER - pattern: '.*<type=ThreadPool, name="(\w+-\w+)-(\d+)"><>(currentThreadCount|currentThreadsBusy|keepAliveCount|pollerThreadCount|connectionCount):' name: tomcat_threadpool_$3 labels: port: "$2" protocol: "$1" help: Tomcat threadpool $3 type: COUNTER - pattern: '.*<type=Manager, host=([-a-zA-Z0-9+&@#/%?=~_|!:.,;]*[-a-zA-Z0-9+&@#/%=~_|]), context=([-a-zA-Z0-9+/$%~_-|!.]*)><>(processingTime|sessionCounter|rejectedSessions|expiredSessions|activeSessions):' name: tomcat_session_$3_total labels: context: "$2" help: Tomcat session $3 total type: GAUGE Can someone help export JAVA_OPTS="-server -Xms64M -Xmx512M -Dfile.encoding=UTF-8" if [[ -n $LD_LIBRARY_PATH ]] then export LD_LIBRARY_PATH="/apps/install/asf-apr/current/lib:$LD_LIBRARY_PATH:$CATALINA_BASE/lib" else export LD_LIBRARY_PATH="/apps/install/asf-apr/current/lib:$CATALINA_BASE/lib" fi export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/apps/install/bsd-openssl/current/lib" export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/apps/install/asf-tomcat-native/current/lib" JMX_OPTION="-Dcom.sun.management.jmxremote\ -Dcom.sun.management.jmxremote.port=10009\ -Dcom.sun.management.jmxremote.ssl=false\ -Dcom.sun.management.jmxremote.password.file=/data/tomcat_test/tomcat/conf/jmxremote.password\ -jar:/data/tomcat_test/tomcat/agents/jmx.jar=9080:/data/tomcat_test/tomcat/agents/tomcat_prometheus.yml" #export JAVA_OPTS="$JAVA_OPTS ${JMX_OPTION}" export CATALINA_OPTS=" $CATALINA_OPTS\ -Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=true\ -Dorg.apache.tomcat.util.http.ServerCookie.FWD_SLASH_IS_SEPARATOR=false\ -Dorg.apache.catalina.connector.RECYCLE_FACADES=false\ -Dorg.apache.catalina.connector.CoyoteAdapter.ALLOW_BACKSLASH=false\ -Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=false\ -Dorg.apache.coyote.USE_CUSTOM_STATUS_MSG_IN_HEADER=false" export CATALINA_OPTS="$CATALINA_OPTS ${JMX_OPTION}" -- You received this message because you are subscribed to the Google Groups "Prometheus Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/2dd6d890-5f16-4c80-9e2d-2c32c5ae6b30n%40googlegroups.com.

