I am trying to connect my docker containers with JConsole or JVisualVM. There are some articles I googled like http://www.jamasoftware.com/blog/monitoring-java-applications/ but that didn't work for me.
How can I connect them to my running container. I am using latest docker for mac, So I don't have docker machine for ip 192.168.99.100
Try setting -Djava.rmi.server.hostname=localhost
along with the other rmi/jmx parameters.
-Dcom.sun.management.jmxremote.rmi.port=9090
-Dcom.sun.management.jmxremote=true
-Dcom.sun.management.jmxremote.port=9090
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
-Dcom.sun.management.jmxremote.local.only=false
-Djava.rmi.server.hostname=localhost