Browse Source
Ignore remote volume when selecting volumes in operation (ec.encode/volume.tier.upload) (#5635)
pull/5638/head
NyaMisty
7 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
4 additions and
0 deletions
-
weed/shell/command_ec_encode.go
|
|
@ -304,6 +304,10 @@ func collectVolumeIdsForEcEncode(commandEnv *CommandEnv, selectedCollection stri |
|
|
|
eachDataNode(topologyInfo, func(dc string, rack RackId, dn *master_pb.DataNodeInfo) { |
|
|
|
for _, diskInfo := range dn.DiskInfos { |
|
|
|
for _, v := range diskInfo.VolumeInfos { |
|
|
|
// ignore remote volumes
|
|
|
|
if v.RemoteStorageName != "" && v.RemoteStorageKey != "" { |
|
|
|
continue |
|
|
|
} |
|
|
|
if v.Collection == selectedCollection && v.ModifiedAtSecond+quietSeconds < nowUnixSeconds { |
|
|
|
if float64(v.Size) > fullPercentage/100*float64(volumeSizeLimitMb)*1024*1024 { |
|
|
|
vidMap[v.Id] = true |
|
|
|