From 0ff9112bc4378d2c10477fcb37e6c4a48ae9cc22 Mon Sep 17 00:00:00 2001 From: jiashuo Date: Mon, 22 Feb 2021 15:22:51 +0800 Subject: [PATCH 01/14] add rfc --- rfcs/2021-02-22-disk-migrater.md | 35 ++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 rfcs/2021-02-22-disk-migrater.md diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md new file mode 100644 index 0000000000..0e80c8a987 --- /dev/null +++ b/rfcs/2021-02-22-disk-migrater.md @@ -0,0 +1,35 @@ +Disk-Migrater is for migrating data among different disk volumns at one node, which is different from [node-balancer](http://pegasus.apache.org/administration/rebalance) that is for migrating data among different nodes. + +Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node and goes on to trigger the node to migrate the `replica` from one disk to another. The whole migration process as follow: + +``` ++---------------+ +---------------+ +--------------+ +| client(shell) +------+ replicaServer +-------+ metaServer | ++------+--------+ +-------+-------+ +-------+------+ + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + | | | + v v v +``` + +* target node receive the migrate-rpc and start validate rpc arguments +* if the rpc is valid, node start migrate `replica` which contain `checkpoint`, `.init-info`,`.app-info` +* after data migrate successfuly, the origin `replica` will be closed and `replica-server` re-opens the new `replica` +* if the `repica` data is inconsistent with other replica, it will be trigger the to `learn` to catch up with the latest data by `meta-server` +* after the `learn` is completed, the `migration` is successful + + + +creating a plan and goes on to execute that plan on the datanode. A plan is a set of statements that describe how much data should move between two disks. A plan is composed of multiple move steps. A move step has source disk, destination disk and number of bytes to move. A plan can be executed against an operational data node. Disk balancer should not interfere with other processes since it throttles how much data is copied every second. Please note that disk balancer is not enabled by default on a cluster. To enable diskbalancer dfs.disk.balancer.enabled must be set to true in hdfs-site.xml. \ No newline at end of file From 9880fb5bb632fd1e9bef8bf7aa4456a5c18f5844 Mon Sep 17 00:00:00 2001 From: jiashuo Date: Mon, 22 Feb 2021 16:36:42 +0800 Subject: [PATCH 02/14] add rfc --- rfcs/2021-02-22-disk-migrater.md | 47 ++++++++++++++++++++------------ 1 file changed, 29 insertions(+), 18 deletions(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 0e80c8a987..44cecc834c 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -1,5 +1,8 @@ +# Disk-Migrater + Disk-Migrater is for migrating data among different disk volumns at one node, which is different from [node-balancer](http://pegasus.apache.org/administration/rebalance) that is for migrating data among different nodes. + Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node and goes on to trigger the node to migrate the `replica` from one disk to another. The whole migration process as follow: ``` @@ -7,29 +10,37 @@ Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node | client(shell) +------+ replicaServer +-------+ metaServer | +------+--------+ +-------+-------+ +-------+------+ | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - | | | - v v v + +------migrateRPC-----> +-----IDLE | + | | | (validate rpc)| + | | MOVING | + | | | (migrate data)| + | | MOVED | + | | | (rename dir) | + | | CLOSED | + | | | | + | +----- +<----LEARN<------------+ + | | | | + | | | | + | LearnSuccess| | + | | | | + | | | | + | +----->+ | ``` * target node receive the migrate-rpc and start validate rpc arguments * if the rpc is valid, node start migrate `replica` which contain `checkpoint`, `.init-info`,`.app-info` * after data migrate successfuly, the origin `replica` will be closed and `replica-server` re-opens the new `replica` -* if the `repica` data is inconsistent with other replica, it will be trigger the to `learn` to catch up with the latest data by `meta-server` +* if the new `repica` data is inconsistent with other replica(new write operation when migrating), it will be trigger to `learn` to catch up with the latest data by `meta-server` * after the `learn` is completed, the `migration` is successful +The `client` sending rpc now is [admin-cli](https://github.com/pegasus-kv/admin-cli) which support `query disk info` and `migrate disk replica`, the command like this(`help` can see the detail command ): +``` +# query replica capacity +disk-capacity -n node -d disk +# query replica count +disk-replica -n node -d disk +# migrate data +disk-migrate -n node -g gpid -f disk1 -t disk2 +``` - -creating a plan and goes on to execute that plan on the datanode. A plan is a set of statements that describe how much data should move between two disks. A plan is composed of multiple move steps. A move step has source disk, destination disk and number of bytes to move. A plan can be executed against an operational data node. Disk balancer should not interfere with other processes since it throttles how much data is copied every second. Please note that disk balancer is not enabled by default on a cluster. To enable diskbalancer dfs.disk.balancer.enabled must be set to true in hdfs-site.xml. \ No newline at end of file +It's noticed that the migration is manual, and we hope the future work is `admin-cli` can create `whole disk balance plan/step` and then automatically migrate data to balance all disk as much as possible \ No newline at end of file From 42e92f6c2c382319a432d03351a8d58f7de56351 Mon Sep 17 00:00:00 2001 From: jiashuo Date: Mon, 22 Feb 2021 17:58:57 +0800 Subject: [PATCH 03/14] add rfc --- rfcs/2021-02-22-disk-migrater.md | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 44cecc834c..9915249097 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -1,8 +1,9 @@ # Disk-Migrater +## Overall Disk-Migrater is for migrating data among different disk volumns at one node, which is different from [node-balancer](http://pegasus.apache.org/administration/rebalance) that is for migrating data among different nodes. - +## Flow Process Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node and goes on to trigger the node to migrate the `replica` from one disk to another. The whole migration process as follow: ``` @@ -33,6 +34,23 @@ Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node * if the new `repica` data is inconsistent with other replica(new write operation when migrating), it will be trigger to `learn` to catch up with the latest data by `meta-server` * after the `learn` is completed, the `migration` is successful +## Replica States +In the process of migration, the `origin replica dir` and `new replica dir` will have different status as follow +| process |origin replica status[dir name] | new replica status[dir name] | +|---|---|---| +|IDEL |primary/secondary[gpid.pegasus] |--[--] | +|START |secondary[gpid.pegasus] |--[--] | +|MOVING |secondary[gpid.pegasus] |--[gpid.pegasus.disk.migrate.tmp] | +|MOVED |secondary[gpid.pegasus] |--[gpid.pegasus.disk.migrate.tmp] | +|CLOSED |error[gpid.pegasus.disk.migrate.ori] |--[gpid.pegasus] | +|LEARNING |error[gpid.pegasus.disk.migrate.ori] |potential_secondary[gpid.pegasus] | +| COMPLETED |error[gpid.pegasus.disk.migrate.ori] |secondary[gpid.pegasus] | + +**Note:** +* if replica status is `primary`, you need assign `secondary` manually via [propose](http://pegasus.apache.org/administration/rebalance) +* any process is failed, the operation will be failed and reverted the `IDEL` status + +## Client Command The `client` sending rpc now is [admin-cli](https://github.com/pegasus-kv/admin-cli) which support `query disk info` and `migrate disk replica`, the command like this(`help` can see the detail command ): ``` # query replica capacity From d575ad69363bab2097bd27f31817af8aaf5ded7c Mon Sep 17 00:00:00 2001 From: jiashuo Date: Mon, 22 Feb 2021 18:03:44 +0800 Subject: [PATCH 04/14] add rfc --- rfcs/2021-02-22-disk-migrater.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 9915249097..4b331d8146 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -35,7 +35,7 @@ Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node * after the `learn` is completed, the `migration` is successful ## Replica States -In the process of migration, the `origin replica dir` and `new replica dir` will have different status as follow +In the process of migration, the `origin replica ` and `new replica` will have different states as follow | process |origin replica status[dir name] | new replica status[dir name] | |---|---|---| |IDEL |primary/secondary[gpid.pegasus] |--[--] | From 1474a02d2697b1c405a2e5fe999b8c94d7606dc1 Mon Sep 17 00:00:00 2001 From: Jiashuo Date: Mon, 1 Mar 2021 10:33:51 +0800 Subject: [PATCH 05/14] Update rfcs/2021-02-22-disk-migrater.md Co-authored-by: Wu Tao --- rfcs/2021-02-22-disk-migrater.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 4b331d8146..c97dcd361f 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -1,7 +1,7 @@ # Disk-Migrater ## Overall -Disk-Migrater is for migrating data among different disk volumns at one node, which is different from [node-balancer](http://pegasus.apache.org/administration/rebalance) that is for migrating data among different nodes. +Disk-Migrater is for migrating data among different local disks within one node. This feature is different from node-rebalance that is for migrating data among different nodes. ## Flow Process Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node and goes on to trigger the node to migrate the `replica` from one disk to another. The whole migration process as follow: @@ -61,4 +61,4 @@ disk-replica -n node -d disk disk-migrate -n node -g gpid -f disk1 -t disk2 ``` -It's noticed that the migration is manual, and we hope the future work is `admin-cli` can create `whole disk balance plan/step` and then automatically migrate data to balance all disk as much as possible \ No newline at end of file +It's noticed that the migration is manual, and we hope the future work is `admin-cli` can create `whole disk balance plan/step` and then automatically migrate data to balance all disk as much as possible From e62bae2ebc0c2af9cb1e2fa6b87129f4ca06bbc6 Mon Sep 17 00:00:00 2001 From: Jiashuo Date: Mon, 1 Mar 2021 10:34:28 +0800 Subject: [PATCH 06/14] Update rfcs/2021-02-22-disk-migrater.md Co-authored-by: Wu Tao --- rfcs/2021-02-22-disk-migrater.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index c97dcd361f..7f93d56e8b 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -4,7 +4,7 @@ Disk-Migrater is for migrating data among different local disks within one node. This feature is different from node-rebalance that is for migrating data among different nodes. ## Flow Process -Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to target node and goes on to trigger the node to migrate the `replica` from one disk to another. The whole migration process as follow: +Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted node that triggers the node to migrate the specified `replica` from one disk to another. The whole migration process is as follow: ``` +---------------+ +---------------+ +--------------+ From 20732403c3a26992fc37037c17e670cbd5e1ea8f Mon Sep 17 00:00:00 2001 From: Jiashuo Date: Mon, 1 Mar 2021 10:40:24 +0800 Subject: [PATCH 07/14] Update rfcs/2021-02-22-disk-migrater.md Co-authored-by: Wu Tao --- rfcs/2021-02-22-disk-migrater.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 7f93d56e8b..12ce627cd4 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -28,11 +28,11 @@ Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted | +----->+ | ``` -* target node receive the migrate-rpc and start validate rpc arguments -* if the rpc is valid, node start migrate `replica` which contain `checkpoint`, `.init-info`,`.app-info` -* after data migrate successfuly, the origin `replica` will be closed and `replica-server` re-opens the new `replica` -* if the new `repica` data is inconsistent with other replica(new write operation when migrating), it will be trigger to `learn` to catch up with the latest data by `meta-server` -* after the `learn` is completed, the `migration` is successful +1. The targeted node receives the migrateRPC and starts validating the request arguments. +2. If the RPC is valid, node starts migrating the specified `replica`. +3. After replica migration finishes successfuly, the original `replica` will be closed and ReplicaServer re-opens the new `replica`. +4. If the new replica's data is inconsistent with its primary, MetaServer will automatically start to trigger replica-learn to catch up with the latest data. +5. After the learning process is completed, the entire disk-migration ends. ## Replica States In the process of migration, the `origin replica ` and `new replica` will have different states as follow From e3c829854f5e90c22966a18986938e70cca44759 Mon Sep 17 00:00:00 2001 From: Jiashuo Date: Mon, 1 Mar 2021 11:05:27 +0800 Subject: [PATCH 08/14] Update rfcs/2021-02-22-disk-migrater.md Co-authored-by: Wu Tao --- rfcs/2021-02-22-disk-migrater.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 12ce627cd4..ca9f29dabf 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -1,6 +1,6 @@ # Disk-Migrater -## Overall +## Design Goals Disk-Migrater is for migrating data among different local disks within one node. This feature is different from node-rebalance that is for migrating data among different nodes. ## Flow Process From c9c6fc48b6318b20e0cd37ea464166f6500d057f Mon Sep 17 00:00:00 2001 From: jiashuo Date: Mon, 1 Mar 2021 11:16:53 +0800 Subject: [PATCH 09/14] fix --- rfcs/2021-02-22-disk-migrater.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index ca9f29dabf..526fc481fa 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -8,7 +8,7 @@ Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted ``` +---------------+ +---------------+ +--------------+ -| client(shell) +------+ replicaServer +-------+ metaServer | +| Client(shell) +------+ replicaServer +-------+ metaServer | +------+--------+ +-------+-------+ +-------+------+ | | | +------migrateRPC-----> +-----IDLE | @@ -47,8 +47,8 @@ In the process of migration, the `origin replica ` and `new replica` will have d | COMPLETED |error[gpid.pegasus.disk.migrate.ori] |secondary[gpid.pegasus] | **Note:** -* if replica status is `primary`, you need assign `secondary` manually via [propose](http://pegasus.apache.org/administration/rebalance) -* any process is failed, the operation will be failed and reverted the `IDEL` status +* If replica status is `primary`, you need assign it `secondary` manually via [propose](http://pegasus.apache.org/administration/rebalance). +* Any process is failed, the operation will be failed and reverted the `IDEL` status. ## Client Command The `client` sending rpc now is [admin-cli](https://github.com/pegasus-kv/admin-cli) which support `query disk info` and `migrate disk replica`, the command like this(`help` can see the detail command ): @@ -61,4 +61,4 @@ disk-replica -n node -d disk disk-migrate -n node -g gpid -f disk1 -t disk2 ``` -It's noticed that the migration is manual, and we hope the future work is `admin-cli` can create `whole disk balance plan/step` and then automatically migrate data to balance all disk as much as possible +It's noticed that the migration is manual, and we hope the future work is `admin-cli` can create `whole disk balance plan/step` and then automatically migrate data to balance all disk as much as possible . From 2898a85a4b8ea07f9f2e24080efaf5ad0d1e7c5b Mon Sep 17 00:00:00 2001 From: Jiashuo Date: Tue, 2 Mar 2021 18:54:07 +0800 Subject: [PATCH 10/14] Update rfcs/2021-02-22-disk-migrater.md Co-authored-by: Wu Tao --- rfcs/2021-02-22-disk-migrater.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 526fc481fa..4020d3b2d8 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -35,7 +35,7 @@ Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted 5. After the learning process is completed, the entire disk-migration ends. ## Replica States -In the process of migration, the `origin replica ` and `new replica` will have different states as follow +In the process of migration, the original replica and the new replica will have different states as follow: | process |origin replica status[dir name] | new replica status[dir name] | |---|---|---| |IDEL |primary/secondary[gpid.pegasus] |--[--] | From 80c63f457ce5204e4f18291c8e055adc28615750 Mon Sep 17 00:00:00 2001 From: Jiashuo Date: Tue, 2 Mar 2021 18:54:40 +0800 Subject: [PATCH 11/14] Update rfcs/2021-02-22-disk-migrater.md Co-authored-by: Wu Tao --- rfcs/2021-02-22-disk-migrater.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 4020d3b2d8..8e37b0e72a 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -51,7 +51,9 @@ In the process of migration, the original replica and the new replica will have * Any process is failed, the operation will be failed and reverted the `IDEL` status. ## Client Command -The `client` sending rpc now is [admin-cli](https://github.com/pegasus-kv/admin-cli) which support `query disk info` and `migrate disk replica`, the command like this(`help` can see the detail command ): +The client sending migrateRPC is [admin-cli](https://github.com/pegasus-kv/admin-cli) which supports `disk-capacity`, `disk-replica` and `disk-migrate` commands. + +Use `help` to see the command manuals. The example: ``` # query replica capacity disk-capacity -n node -d disk From be2a97fbc90735ee16a143ad311ff5b967d3b389 Mon Sep 17 00:00:00 2001 From: Jiashuo Date: Tue, 2 Mar 2021 18:55:06 +0800 Subject: [PATCH 12/14] Update rfcs/2021-02-22-disk-migrater.md Co-authored-by: Wu Tao --- rfcs/2021-02-22-disk-migrater.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index 8e37b0e72a..d54f943636 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -63,4 +63,4 @@ disk-replica -n node -d disk disk-migrate -n node -g gpid -f disk1 -t disk2 ``` -It's noticed that the migration is manual, and we hope the future work is `admin-cli` can create `whole disk balance plan/step` and then automatically migrate data to balance all disk as much as possible . +It should be noticed that disk migration is currently a manual operation. It's in our future plan to design a disk-rebalance planner. It can generate a series of steps, which automatically migrate data and eventually make all disks balanced. From e85a44ebef96c56fef70a2b60b5242e2efb87b3f Mon Sep 17 00:00:00 2001 From: jiashuo Date: Tue, 2 Mar 2021 18:56:54 +0800 Subject: [PATCH 13/14] init --- rfcs/2021-02-22-disk-migrater.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrater.md index d54f943636..365862d185 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrater.md @@ -4,7 +4,7 @@ Disk-Migrater is for migrating data among different local disks within one node. This feature is different from node-rebalance that is for migrating data among different nodes. ## Flow Process -Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted node that triggers the node to migrate the specified `replica` from one disk to another. The whole migration process is as follow: +Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted node that triggers the node to migrate the specified replica from one disk to another. The whole migration process is as follow: ``` +---------------+ +---------------+ +--------------+ @@ -29,8 +29,8 @@ Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted ``` 1. The targeted node receives the migrateRPC and starts validating the request arguments. -2. If the RPC is valid, node starts migrating the specified `replica`. -3. After replica migration finishes successfuly, the original `replica` will be closed and ReplicaServer re-opens the new `replica`. +2. If the RPC is valid, node starts migrating the specified replica. +3. After replica migration finishes successfuly, the original replica will be closed and ReplicaServer re-opens the new replica. 4. If the new replica's data is inconsistent with its primary, MetaServer will automatically start to trigger replica-learn to catch up with the latest data. 5. After the learning process is completed, the entire disk-migration ends. From 610cf51f37843207e9bb58e4833f1f3f7ecab6f5 Mon Sep 17 00:00:00 2001 From: jiashuo Date: Mon, 15 Mar 2021 11:23:05 +0800 Subject: [PATCH 14/14] init --- ...-disk-migrater.md => 2021-02-22-disk-migrator.md} | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) rename rfcs/{2021-02-22-disk-migrater.md => 2021-02-22-disk-migrator.md} (85%) diff --git a/rfcs/2021-02-22-disk-migrater.md b/rfcs/2021-02-22-disk-migrator.md similarity index 85% rename from rfcs/2021-02-22-disk-migrater.md rename to rfcs/2021-02-22-disk-migrator.md index 365862d185..b291fddf33 100644 --- a/rfcs/2021-02-22-disk-migrater.md +++ b/rfcs/2021-02-22-disk-migrator.md @@ -1,10 +1,10 @@ -# Disk-Migrater +# Disk-Migrator ## Design Goals -Disk-Migrater is for migrating data among different local disks within one node. This feature is different from node-rebalance that is for migrating data among different nodes. +Disk-Migrator is used for migrating data among different local disks within one node. This feature is different from node-rebalance that is for migrating data among different nodes. ## Flow Process -Disk-Migrater operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted node that triggers the node to migrate the specified replica from one disk to another. The whole migration process is as follow: +Disk-Migrator operates by sending `RPC_REPLICA_DISK_MIGRATE` rpc to the targeted node that triggers the node to migrate the specified replica from one disk to another. The whole migration process is as follow: ``` +---------------+ +---------------+ +--------------+ @@ -47,13 +47,13 @@ In the process of migration, the original replica and the new replica will have | COMPLETED |error[gpid.pegasus.disk.migrate.ori] |secondary[gpid.pegasus] | **Note:** -* If replica status is `primary`, you need assign it `secondary` manually via [propose](http://pegasus.apache.org/administration/rebalance). -* Any process is failed, the operation will be failed and reverted the `IDEL` status. +* If replica status is `primary`, you need assign it as `secondary` manually via [propose](http://pegasus.apache.org/administration/rebalance). +* Once any process is failed, the operation will be failed and reverted the `IDEL` status. ## Client Command The client sending migrateRPC is [admin-cli](https://github.com/pegasus-kv/admin-cli) which supports `disk-capacity`, `disk-replica` and `disk-migrate` commands. -Use `help` to see the command manuals. The example: +Use `help` to see the command manuals. For example: ``` # query replica capacity disk-capacity -n node -d disk