jvm-profiling-tools / perf-map-agent

A java agent to generate method mappings to use with the linux `perf` tool
GNU General Public License v2.0
1.64k stars 260 forks source link

./bin/dtrace-java-record-stack is not working #87

Open anianna96 opened 3 years ago

anianna96 commented 3 years ago

Ran ./bin/dtrace-java-record-stack but the command does not work. I think the dtrace command inside the ./bin/dtrace-java-record-stack is not used properly.

cat /tmp/dtrace-25840.data Usage /usr/bin/dtrace [--help] [-h | -G] [-C [-I]] -s File.d [-o ]

anianna96 commented 3 years ago
bash -x ./bin/dtrace-java-record-stack 25840
+ set -e
+++ dirname ./bin/dtrace-java-record-stack
++ cd ./bin
++ pwd -P
+ PERF_MAP_DIR=/home/master/perf-map-agent-master/bin/..
+ PID=25840
+ '[' -z '' ']'
+ DTRACE_JAVA_TMP=/tmp
+ '[' -z '' ']'
+ DTRACE_SECONDS=15
+ '[' -z '' ']'
+ DTRACE_FREQ=99
+ '[' -z '' ']'
+ DTRACE_FRAMES=100
+ '[' -z '' ']'
+ DTRACE_DATA_FILE=/tmp/dtrace-25840.data
+ sudo dtrace -x ustackframes=100 -n 'profile-99 /pid == 25840 && arg1/ { @[ustack()] = count(); } tick-15s { exit(0); }' -p 25840