Skip to content

Commit

Permalink
Add docs on how to get goroutine dump
Browse files Browse the repository at this point in the history
Signed-off-by: Stefan Büringer buringerst@vmware.com
  • Loading branch information
sbueringer authored and k8s-infra-cherrypick-robot committed Apr 19, 2024
1 parent 1291f05 commit 5fc3d2a
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions docs/book/src/tasks/diagnostics.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,11 @@ kubectl -n capi-system port-forward deployments/capi-controller-manager 8443

# Terminal 2
TOKEN=$(kubectl create token default)

# Get a goroutine dump
curl "https://localhost:8443/debug/pprof/goroutine?debug=2" --header "Authorization: Bearer $TOKEN" -k > ./goroutine.txt

# Get a profile
curl "https://localhost:8443/debug/pprof/profile?seconds=10" --header "Authorization: Bearer $TOKEN" -k > ./profile.out
go tool pprof -http=:8080 ./profile.out
```
Expand Down

0 comments on commit 5fc3d2a

Please sign in to comment.