Can't convert hprof dump
Asked Answered
A

1

6

I try convert dump from Android Device Monitor to Eclipse Memory Analyzer format. I use next command

hprof-conv dump.hprof converted-dump.hprof

and i get error

hprof-conv: command not found

I do this in a /platform-tools folder. When I run the same command on another computer everything works fine.What is problem?

Antechoir answered 8/5, 2015 at 10:9 Comment(0)
D
11

to run a binary from the current directory you need to prepend ./ to the name of the binary or use the full qualified path to the binary. E.g. if you are in platform-tools you can run

./hprof-conv /path/to/dump.hprof /path/to/converted-dump.hprof

if you are in the directory where dump.hprof is stored you need

/path/to/platform-tools/hprof-conv  dump.hprof converted-dump.hprof

or you could add tools and platform-tools to $PATH. To do so, edit .bashrc. E.g.

vim .bashrc
export PATH=${PATH}:~/path/to/sdk/tools
export PATH=${PATH}:~/path/to/sdk/platform-tools

save it, and the run source /etc/profile, and you should be able to run every binary in tools and platform-tools without the path or the ./

Disown answered 8/5, 2015 at 10:27 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.