diff --git a/cmd/utils.go b/cmd/utils.go index d2c53af5f..544c20d99 100644 --- a/cmd/utils.go +++ b/cmd/utils.go @@ -320,8 +320,7 @@ func startProfiler(profilerType string) (minioProfiler, error) { defer os.RemoveAll(dirPath) return ioutil.ReadFile(fn) } - // TODO(klauspost): Replace with madmin.ProfilerCPUIO on next update. - case "cpuio": + case madmin.ProfilerCPUIO: // at 10k or more goroutines fgprof is likely to become // unable to maintain its sampling rate and to significantly // degrade the performance of your application @@ -339,10 +338,6 @@ func startProfiler(profilerType string) (minioProfiler, error) { return nil, err } stop := fgprof.Start(f, fgprof.FormatPprof) - err = pprof.StartCPUProfile(f) - if err != nil { - return nil, err - } prof.stopFn = func() ([]byte, error) { err := stop() if err != nil {