英文:
The pprof heap report displays raw memory addresses
问题
根据您提供的内容,以下是翻译的结果:
根据这个指南http://golang.org/pkg/net/http/pprof/,我正在尝试查看堆报告。当我导航到适当的URL时,显示的内容如下:
<!-- 来源:http://oi41.tinypic.com/14ag7iw.jpg -->
我尝试过ActivePerl、StrawberryPerl和随MSYS工具一起提供的Perl。问题出在哪里?
英文:
Following this guide http://golang.org/pkg/net/http/pprof/, i'm trying to look at the heap report. When i navigate to the appropriate url, this is what is displayed:
<!-- source: http://oi41.tinypic.com/14ag7iw.jpg -->
I tried this with ActivePerl, StrawberryPerl and the Perl coming with MSYS tools. What is the issue here?
答案1
得分: 2
net/http/pprof包的输出最好与go tool pprof
一起使用。如果您的服务器正在监听6060端口,您将需要一个命令,例如go tool pprof http://localhost:6060/debug/pprof/heap
。在net/http/pprof包的文档中有关于如何使用pprof工具的解释,您可以在http://blog.golang.org/profiling-go-programs找到相关链接。
如果您真的有兴趣尝试自己阅读输出结果,您可以在之前尝试的URL中添加?debug=1
,但我不建议这样做。
英文:
The output of the net/http/pprof package is best used with go tool pprof
. If your server is listening on port 6060, you'll want a command like go tool pprof http://localhost:6060/debug/pprof/heap
. There's an explanation of how to use the pprof tool at http://blog.golang.org/profiling-go-programs, which is linked from the net/http/pprof package docs.
If you're really interested in trying to read the output yourself, you can add ?debug=1
to the url you tried before - but I can't recommend it.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论