This is what I have done so far:
-Dcom.sun.management.jmxremote.port=3939
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
But when I am trying to connect to jmx using JVisualVm or JDK mission control it is unable to connect. Am I missing something here ?
Finally it worked after I added below mentioned property which forces rmi port to be same as jmx port instead of opening a random port which was not opened from security group.
-Dcom.sun.management.jmxremote.rmi.port=3939
Thanks to these stackoverflow posts: