Jprofiler Remote profiling on linux. How to change

2019-07-05 12:34发布

问题:

I am running java (java 6) application on linux box with additional settings -agentpath:/home/myuser/jprofiler/bin/linux-x64/libjprofilerti.so=nowait,port=7777 Using JProfiler 7.2.1 on Win box I can connect to the process and retrieve profiling data.

I can see that on Linux box JProfiler generates some files under "/tmp" directory. Name of the files are always different (now it is "jagJGZkk1" and "jdcEoM0XI"). Because of huge size of heap (around 15 GB) and small available size of "/tmp" I cannot make a memory snapshot - "/tmp" becomes full as JProfiler's files grow in size.

How can I change the path for JProfiler's data files? Are there any properties/workaround?

Thanks

回答1:

To change the temporary directory used by Java, edit bin/jprofiler.vmoptions in the JProfiler installation directory and add a line

-Djava.io.tmpdir=[path to your temp dir]