aboutsummaryrefslogtreecommitdiff
path: root/weed/shell/command_volume_balance.go
diff options
context:
space:
mode:
authorchrislu <chris.lu@gmail.com>2023-02-09 22:17:54 -0800
committerchrislu <chris.lu@gmail.com>2023-02-09 22:17:54 -0800
commitdc4ed2cd9b66ea390aa5d295fe6b841c9e79a5b2 (patch)
treeb88efb17fe9891807c73742f4d9ace324ba7bd7a /weed/shell/command_volume_balance.go
parent31bb91583f1523c635d691de2c7941a35ac26fd6 (diff)
downloadseaweedfs-dc4ed2cd9b66ea390aa5d295fe6b841c9e79a5b2.tar.xz
seaweedfs-dc4ed2cd9b66ea390aa5d295fe6b841c9e79a5b2.zip
do not move cloud tier volumes
fix https://github.com/seaweedfs/seaweedfs/issues/4195
Diffstat (limited to 'weed/shell/command_volume_balance.go')
-rw-r--r--weed/shell/command_volume_balance.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/weed/shell/command_volume_balance.go b/weed/shell/command_volume_balance.go
index 3a9e7dea0..5380d5e63 100644
--- a/weed/shell/command_volume_balance.go
+++ b/weed/shell/command_volume_balance.go
@@ -329,6 +329,10 @@ func maybeMoveOneVolume(commandEnv *CommandEnv, volumeReplicas map[uint32][]*Vol
return false, fmt.Errorf("lock is lost")
}
+ if candidateVolume.RemoteStorageName != "" {
+ return false, nil
+ }
+
if candidateVolume.ReplicaPlacement > 0 {
replicaPlacement, _ := super_block.NewReplicaPlacementFromByte(byte(candidateVolume.ReplicaPlacement))
if !isGoodMove(replicaPlacement, volumeReplicas[candidateVolume.Id], fullNode, emptyNode) {