0

VisualVM connects to a local karaf instance without any problems but will not make a remote connection. Others on my team have this remote connection working.

Also VisualVM hangs when I go to VisualVM > Preferences ... > Network

This leads me to believe it may be some kind of permission/firewall problem. I am on OSX 11.4 Big Sur, VisualVM is version 2.0.7.

The firewall log at /private/var/log/appfirewall.log is empty because apparently it only logs user-defined rules.

I don't know if VisualVM has any logs, have not found them yet.

Ivana
  • 643
  • 10
  • 27

1 Answers1

0

It turns out the connection failed because there was a hard to spot typo in the remote url. When i fixed the typo, the connection became available. Found this out using jconsole which comes standard with jdk, and does give you an error when the connection url is faulty.

tl;dr Try a different tool before trying to troubleshoot with VisualVM.

Regarding troubleshooting with VisualVM:

  1. VisualVM hangs on VisualVM > Preferences ... > Network regardless.

  2. The connection problems do not show up in the log.

Logging for VirtualVM is enabled by setting the log properties the /Applications/VisualVM.app/Contents/Resources/visualvm/etc/visualvm.conf file. You do this by adding J-Djava.util.logging.config.file=<log.properties> to the list in visualvm_default_options.

In your log.properties file you define the log-file and log-level, as usual:

handlers = java.util.logging.FileHandler
java.util.logging.FileHandler.pattern   = ~/visualvm.log
java.util.logging.FileHandler.level   = INFO
Ivana
  • 643
  • 10
  • 27