I'm trying to connect JProfiler to a JVM running on a server that I'll call remote. This server is only accessible from my workstation (local) via another server that I'll call middle. My plan for connecting JProfiler to remote was this:
Install the JProfiler instrumentation on remote
Establish SSH tunnel from local, through middle, to remote:
ssh -v -N -L 8849:[remote's private address (192.168... etc)]:8849 [middle]
- Establish a new JProfiler session on
localhost:8849
, choosing "Startup immediately, connect later with JProfiler GUI"
However, I end up getting an error:
Connection error
Either an old version of the native library is used or another application is listening on port 8849. Please check your DYLD_LIBRARY_PATH environment variable and your port configuration
I don't have any other programs bound to local port 8849, aside from my SSH tunnel, and I have confirmed that the SSH tunnel itself should be working correctly - I'm able to forward connections for a test HTTP server from remote to local via a similarly configured tunnel.
I found this similar question, but no solution was provided.
What am I missing from my configuration?