I am new to Java and I\'m facing a problem in connecting a Remote Host to the JVisualVM
.
I\'ve searched the Internet and followed all the steps mentioned th
Start jstatd in nohup on the server which needs to be monitored and connect VisualVM
to the jstatd port, following below steps:
Step 1 : Create start-jstatd.sh
and copy the below content:
nohup jstatd -p 1099 -J-Djava.security.policy=<(echo 'grant codebase "file:${java.home}/../lib/tools.jar" {permission java.security.AllPermission;};') &
Step 2: Give executable permission to the file:
$ chmod a+rwx start-jstatd.sh
Step 3: Start jstatd:
$ sh start-jstatd.sh
Step 4: Add Remote Host in VisualVM
:
Step 5: Add JMX Connection to the Remote Host, as shown in the below image and Click OK button: