My application is running on CentOS,and when I run curl localhost:port/debug/pprof/profile > some.pprof
,and run go tool pprof some.pprof
, it works. But When I use scp
copying the some.pprof
file to my mac and run go tool pprof some.pprof
,it doesn't work any more,command top
display only 1 line in which flat and sum both are 100% and the last row is the name of my application rather than the name of methods invoked.
Isn't the pprof file cross platform or something I've misused?
Asked
Active
Viewed 340 times
0

caibirdme
- 371
- 1
- 3
- 15
-
2pprof depends on the binary used to generate the profile. – Adrian Aug 15 '17 at 12:54
-
1Yes. I taken pprof data and binaries from Linux servers and profiled them on macOS many times. – JimB Aug 15 '17 at 13:15
-
Thx a lot,it works – caibirdme Aug 16 '17 at 03:09
1 Answers
0
as Adrian said, the binary is required for running pprof. So download the binary from server,put it into the same path on server, and it works

caibirdme
- 371
- 1
- 3
- 15