Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/pprof: linux CPU profiles disable remote symbolization #16159

Closed
rhysh opened this issue Jun 23, 2016 · 0 comments
Closed

cmd/pprof: linux CPU profiles disable remote symbolization #16159

rhysh opened this issue Jun 23, 2016 · 0 comments
Assignees
Milestone

Comments

@rhysh
Copy link
Contributor

@rhysh rhysh commented Jun 23, 2016

  1. What version of Go are you using (go version)?

My server is built with go1.7beta2 (go version devel +fca9fc5 Thu Jun 16 19:45:33 2016 +0000 linux/amd64).

I'm using go tool pprof from go1.7beta2 and a more recent version of tip:
go version devel +fca9fc5 Thu Jun 16 19:45:33 2016 +0000 darwin/amd64
go version devel +395f6eb Wed Jun 22 21:15:51 2016 +0000 darwin/amd64

  1. What operating system and processor architecture are you using (go env)?

linux/amd64 server, darwin/amd64 for go tool pprof

  1. What did you do?

I ran go tool pprof http://.../debug/pprof/profile from my darwin/amd64 machine to collect and view a CPU profile over the network of a process running on linux/amd64 (with the web and top subcommands).

  1. What did you expect to see?

I expected the profile to include the names of the functions that were being executed, as collected by a follow-up call to the /debug/pprof/symbol endpoint.

  1. What did you see instead?

The profile did not include function names, and all of the CPU cycles were attributed to a single node (named after the app).

I switched to "addresses" mode, and saw that CPU cycles were attributed to many different addresses (as I'd expect).

I suspect this is related to 4223294 and so only affects GOOS=linux profilees; that the presence of the mapping paths causes go tool pprof to attempt local symbolization and to not try the remote mode.

This doesn't appear to be #16128, as I'm able to reproduce it with a version of go tool pprof that includes 252eda4.

I included the -symbolize=remote flag in my invocation of go tool pprof, and the resulting profile included function names. The "heap" profile works as expected without adding that flag. Remote CPU profiles should work without that flag (as they do in go1.6.x and earlier).

@ianlancetaylor ianlancetaylor added this to the Go1.7 milestone Jun 23, 2016
@ianlancetaylor ianlancetaylor self-assigned this Jun 24, 2016
@gopherbot gopherbot closed this in 4fcb4eb Jun 25, 2016
@golang golang locked and limited conversation to collaborators Jun 25, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.