diff options
| author | Yu-Ju Hong <yjhong@google.com> | 2015-02-20 10:21:20 -0800 |
|---|---|---|
| committer | Yu-Ju Hong <yjhong@google.com> | 2015-02-20 10:21:20 -0800 |
| commit | 404a276a80f0e49c9dec5fb9c83d3d1cc0e782a1 (patch) | |
| tree | fe5687b7951b3042e0918695eb924774bd26c0b0 | |
| parent | 0e7dfbc995f979400dae9c740fe8fa8ea6203c49 (diff) | |
| parent | a65c29ed5cd9092522b0b6e4791984e2dabe5bce (diff) | |
Merge pull request #4590 from gmarek/client3
Add info about contention profiling to profiling.md
| -rw-r--r-- | profiling.md | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/profiling.md b/profiling.md index 68d1cc24..1e14b5c4 100644 --- a/profiling.md +++ b/profiling.md @@ -23,8 +23,12 @@ Even when running profiler I found not really straightforward to use 'go tool pp ``` ssh kubernetes_master -L<local_port>:localhost:8080 ``` -or analogous one for you Cloud provider. Afterwards you can e.g. run +or analogous one for you Cloud provider. Afterwards you can e.g. run ``` go tool pprof http://localhost:<local_port>/debug/pprof/profile ``` to get 30 sec. CPU profile. + +## Contention profiling + +To enable contetion profiling you need to add line ```rt.SetBlockProfileRate(1)``` in addition to ```m.mux.HandleFunc(...)``` added before (```rt``` stands for ```runtime``` in ```master.go```). This enables 'debug/pprof/block' subpage, which can be used as an input to ```go tool pprof```. |
