jvm-profiling-tools / honest-profiler

A sampling JVM profiler without the safepoint sample bias
https://github.com/RichardWarburton/honest-profiler/wiki
MIT License
1.25k stars 146 forks source link

MAC OS X won't launch gui or console #170

Closed champagnetony closed 7 years ago

champagnetony commented 7 years ago

./gui readlink: illegal option -- f usage: readlink [-n] [file ...]

champagnetony commented 7 years ago

And now on ubuntu! ./gui readlink: missing operand

PhRX commented 7 years ago

On Linux Mint and on debian, both ./gui and ./console don't do anything at all. It looks like the readlink usage (in the console script at least, didn't yet check the gui script) is the issue.

Example, on Linux Mint : $ readlink honest-profiler.jar

$ readlink -f honest-profiler.jar /opt/honest-profiler/20160916/honest-profiler.jar
kylejmcintyre commented 7 years ago

On Mac you can brew install coreutils and replace the 'readlink' invocations with 'greadlink' and all will be well...

champagnetony commented 7 years ago

Thank you for the responses - I plan to try the "brew install coreutils" solutions - but as a work around I installed a CentOS VM.

champagnetony commented 7 years ago

Hi All - I tried the coreutils fix but it still did not help. The reason is that the way Java is installed on my Mac (OS Sierra) is not the old way in the /System/Library/Frameworks/JavaVM.framework/Versions/A ... directory. Only the commands are installed there, but JAVA_HOME is actually /Library/Java/JavaVirtualMachines/jdk1.8.0_25.jdk/Contents/Home. So I went into the scripts and change the tools_path to tools_path="$JAVA_HOME/lib/tools.jar". Now the gui and console work.

sattishv commented 6 years ago

Hi team,

After tweaking readlink path to greadlink in gui script on Mac OS and changing the java_home i could invoke the gui in my Mac env.But while trying to open the *.hpl file generated from one of my application deployed in linux i could see only "No content in table". I dont see any errors in console from where i invoked the gui script. Could you please review this.

15:49:43.972 [Thread-5] DEBUG com.insightfullogic.honest_profiler.core.ThreadedAgent - Started 15:49:53.996 [pool-2-thread-1] DEBUG com.insightfullogic.honest_profiler.core.Conductor - Reached end of log for FileLogSource{file=/Users/sattivasudevan/Downloads/FeatureTesting/30min_pas_log.hpl} due to NOTHING

Thanks Sattish.

thuyvu45 commented 5 years ago

I've changed the gui and console tool to use "readlink -n" instead of "readlink -f" everything works.