From c5b3a675fa310e7e010980eb3faa03bf3f9f6a73 Mon Sep 17 00:00:00 2001 From: Klaus Post Date: Sat, 27 Feb 2021 09:22:14 -0800 Subject: [PATCH] Block profiling tweaks (#11612) The base profiles contains no valuable data, don't record them. Reduce block rate by 2 orders of magnitude, should still capture just as valuable data with less CPU strain. --- cmd/utils.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cmd/utils.go b/cmd/utils.go index d8499d931..ac433566d 100644 --- a/cmd/utils.go +++ b/cmd/utils.go @@ -322,8 +322,7 @@ func startProfiler(profilerType string) (minioProfiler, error) { return buf.Bytes(), err } case madmin.ProfilerBlock: - prof.recordBase("block", 0) - runtime.SetBlockProfileRate(1) + runtime.SetBlockProfileRate(100) prof.stopFn = func() ([]byte, error) { var buf bytes.Buffer err := pprof.Lookup("block").WriteTo(&buf, 0)