diff options
| author | hilimd <68371223+hilimd@users.noreply.github.com> | 2020-10-14 16:39:45 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-10-14 16:39:45 +0800 |
| commit | a91137579857a3ef40725dccda85f40d0ac77223 (patch) | |
| tree | ab389cfefe7796600aeaca14773992daf7746752 /weed/shell/command_volume_server_evacuate.go | |
| parent | 2ff727a32d6d879a49ff5848b592518c96bb6403 (diff) | |
| parent | 1069b325dd92b6a1b16a20290acc8129d5e19ef8 (diff) | |
| download | seaweedfs-a91137579857a3ef40725dccda85f40d0ac77223.tar.xz seaweedfs-a91137579857a3ef40725dccda85f40d0ac77223.zip | |
Merge pull request #26 from chrislusf/master
sync
Diffstat (limited to 'weed/shell/command_volume_server_evacuate.go')
| -rw-r--r-- | weed/shell/command_volume_server_evacuate.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/weed/shell/command_volume_server_evacuate.go b/weed/shell/command_volume_server_evacuate.go index 214783ee1..a82454cd3 100644 --- a/weed/shell/command_volume_server_evacuate.go +++ b/weed/shell/command_volume_server_evacuate.go @@ -9,6 +9,7 @@ import ( "github.com/chrislusf/seaweedfs/weed/storage/needle" "github.com/chrislusf/seaweedfs/weed/storage/super_block" "io" + "os" "sort" ) @@ -151,6 +152,11 @@ func moveAwayOneEcVolume(commandEnv *CommandEnv, ecShardInfo *master_pb.VolumeEc for i := 0; i < len(otherNodes); i++ { emptyNode := otherNodes[i] + collectionPrefix := "" + if ecShardInfo.Collection != "" { + collectionPrefix = ecShardInfo.Collection + "_" + } + fmt.Fprintf(os.Stdout, "moving ec volume %s%d.%d %s => %s\n", collectionPrefix, ecShardInfo.Id, shardId, thisNode.info.Id, emptyNode.info.Id) err = moveMountedShardToEcNode(commandEnv, thisNode, ecShardInfo.Collection, needle.VolumeId(ecShardInfo.Id), shardId, emptyNode, applyChange) if err != nil { return |
