aboutsummaryrefslogtreecommitdiff
path: root/weed/command/volume.go
diff options
context:
space:
mode:
authormsementsov <47177265+m-sementsov@users.noreply.github.com>2025-12-05 23:24:38 +0300
committerGitHub <noreply@github.com>2025-12-05 12:24:38 -0800
commitc0dad091f149d80c6737f006c7ab98f4cd69478b (patch)
tree81001c4dc20746261701723b63c7669029a884c3 /weed/command/volume.go
parent4cc6a2a4e58ac03ae79816b636bc8bbf5797b707 (diff)
downloadseaweedfs-c0dad091f149d80c6737f006c7ab98f4cd69478b.tar.xz
seaweedfs-c0dad091f149d80c6737f006c7ab98f4cd69478b.zip
Separate vacuum speed from replication speed (#7632)
Diffstat (limited to 'weed/command/volume.go')
-rw-r--r--weed/command/volume.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/weed/command/volume.go b/weed/command/volume.go
index 514553172..ae9f5e7f4 100644
--- a/weed/command/volume.go
+++ b/weed/command/volume.go
@@ -58,6 +58,7 @@ type VolumeServerOptions struct {
cpuProfile *string
memProfile *string
compactionMBPerSecond *int
+ maintenanceMBPerSecond *int
fileSizeLimitMB *int
concurrentUploadLimitMB *int
concurrentDownloadLimitMB *int
@@ -96,6 +97,7 @@ func init() {
v.cpuProfile = cmdVolume.Flag.String("cpuprofile", "", "cpu profile output file")
v.memProfile = cmdVolume.Flag.String("memprofile", "", "memory profile output file")
v.compactionMBPerSecond = cmdVolume.Flag.Int("compactionMBps", 0, "limit background compaction or copying speed in mega bytes per second")
+ v.maintenanceMBPerSecond = cmdVolume.Flag.Int("maintenanceMBps", 0, "limit maintenance (replication / balance) IO rate in MB/s. Unset is 0, no limitation.")
v.fileSizeLimitMB = cmdVolume.Flag.Int("fileSizeLimitMB", 256, "limit file size to avoid out of memory")
v.ldbTimeout = cmdVolume.Flag.Int64("index.leveldbTimeout", 0, "alive time for leveldb (default to 0). If leveldb of volume is not accessed in ldbTimeout hours, it will be off loaded to reduce opened files and memory consumption.")
v.concurrentUploadLimitMB = cmdVolume.Flag.Int("concurrentUploadLimitMB", 256, "limit total concurrent upload size")
@@ -267,6 +269,7 @@ func (v VolumeServerOptions) startVolumeServer(volumeFolders, maxVolumeCounts, v
v.whiteList,
*v.fixJpgOrientation, *v.readMode,
*v.compactionMBPerSecond,
+ *v.maintenanceMBPerSecond,
*v.fileSizeLimitMB,
int64(*v.concurrentUploadLimitMB)*1024*1024,
int64(*v.concurrentDownloadLimitMB)*1024*1024,