diff options
Diffstat (limited to 'weed/command/filer.go')
| -rw-r--r-- | weed/command/filer.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/weed/command/filer.go b/weed/command/filer.go index 0f1e63df6..4fd2f9c72 100644 --- a/weed/command/filer.go +++ b/weed/command/filer.go @@ -52,6 +52,7 @@ type FilerOptions struct { defaultLevelDbDirectory *string concurrentUploadLimitMB *int debug *bool + debugPort *int } func init() { @@ -75,7 +76,8 @@ func init() { f.saveToFilerLimit = cmdFiler.Flag.Int("saveToFilerLimit", 0, "files smaller than this limit will be saved in filer store") f.defaultLevelDbDirectory = cmdFiler.Flag.String("defaultStoreDir", ".", "if filer.toml is empty, use an embedded filer store in the directory") f.concurrentUploadLimitMB = cmdFiler.Flag.Int("concurrentUploadLimitMB", 128, "limit total concurrent upload size") - f.debug = cmdFiler.Flag.Bool("debug", false, "generate full goroutine stack dump http://localhost:6060/debug/pprof/goroutine?debug=2") + f.debug = cmdFiler.Flag.Bool("debug", false, "serves runtime profiling data, e.g., http://localhost:<debug.port>/debug/pprof/goroutine?debug=2") + f.debugPort = cmdFiler.Flag.Int("debug.port", 6060, "http port for debugging") // start s3 on filer filerStartS3 = cmdFiler.Flag.Bool("s3", false, "whether to start S3 gateway") @@ -126,7 +128,7 @@ var cmdFiler = &Command{ func runFiler(cmd *Command, args []string) bool { if *f.debug { - go http.ListenAndServe(":6060", nil) + go http.ListenAndServe(fmt.Sprintf(":%d", *f.debugPort), nil) } util.LoadConfiguration("security", false) |
