From 677bd52b4ae3fd65a7355791d6f53b0a77f5f511 Mon Sep 17 00:00:00 2001 From: Leeshine Date: Tue, 14 Nov 2017 23:43:37 +0800 Subject: [PATCH 1/2] rgw: add metadata sync related cmd into radosgw-admin help info + radosgw-admin metadata sync status + radosgw-admin metadata sync init + radosgw-admin metadata sync run Signed-off-by: lvshanchun --- doc/man/8/radosgw-admin.rst | 9 +++++++++ src/rgw/rgw_admin.cc | 3 +++ src/test/cli/radosgw-admin/help.t | 3 +++ 3 files changed, 15 insertions(+) diff --git a/doc/man/8/radosgw-admin.rst b/doc/man/8/radosgw-admin.rst index d5300d5f860..4d27b0a42be 100644 --- a/doc/man/8/radosgw-admin.rst +++ b/doc/man/8/radosgw-admin.rst @@ -131,6 +131,15 @@ which are as follows: :command:`zone list` List all zones set on this cluster. +:command:`metadata sync status` + Get metadata sync status. + +:command:`metadata sync init` + Init metadata sync. + +:command:`metadata sync run` + Run metadata sync. + :command:`pool add` Add an existing pool for data placement. diff --git a/src/rgw/rgw_admin.cc b/src/rgw/rgw_admin.cc index 61220f36a76..a750a9950d5 100644 --- a/src/rgw/rgw_admin.cc +++ b/src/rgw/rgw_admin.cc @@ -143,6 +143,9 @@ void usage() cout << " zone placement add add a zone placement target\n"; cout << " zone placement modify modify a zone placement target\n"; cout << " zone placement rm remove a zone placement target\n"; + cout << " metadata sync status get metadata sync status\n"; + cout << " metadata sync init init metadata sync\n"; + cout << " metadata sync run run metadata sync\n"; cout << " pool add add an existing pool for data placement\n"; cout << " pool rm remove an existing pool from data placement set\n"; cout << " pools list list placement active set\n"; diff --git a/src/test/cli/radosgw-admin/help.t b/src/test/cli/radosgw-admin/help.t index 95146a91ba2..cb4c4ae9cec 100644 --- a/src/test/cli/radosgw-admin/help.t +++ b/src/test/cli/radosgw-admin/help.t @@ -86,6 +86,9 @@ zone placement add add a zone placement target zone placement modify modify a zone placement target zone placement rm remove a zone placement target + metadata sync status get metadata sync status + metadata sync init init metadata sync + metadata sync run run metadata sync pool add add an existing pool for data placement pool rm remove an existing pool from data placement set pools list list placement active set From 8f56897c43221044ae5ae727336ec519b514795c Mon Sep 17 00:00:00 2001 From: lvshanchun Date: Tue, 14 Nov 2017 17:05:00 -0500 Subject: [PATCH 2/2] rgw: add data sync related cmd into radosgw-admin help info + radosgw-admin data sync status + radosgw-admin data sync init + radosgw-admin data sync run Signed-off-by: lvshanchun --- doc/man/8/radosgw-admin.rst | 13 +++++++++++++ src/rgw/rgw_admin.cc | 3 +++ src/test/cli/radosgw-admin/help.t | 3 +++ 3 files changed, 19 insertions(+) diff --git a/doc/man/8/radosgw-admin.rst b/doc/man/8/radosgw-admin.rst index 4d27b0a42be..edbf883ff70 100644 --- a/doc/man/8/radosgw-admin.rst +++ b/doc/man/8/radosgw-admin.rst @@ -140,6 +140,15 @@ which are as follows: :command:`metadata sync run` Run metadata sync. +:command:`data sync status` + Get data sync status of the specified source zone. + +:command:`data sync init` + Init data sync for the specified source zone. + +:command:`data sync run` + Run data sync for the specified source zone. + :command:`pool add` Add an existing pool for data placement. @@ -354,6 +363,10 @@ Options Zone in which radosgw is running. +.. option:: --source-zone= + + Specify the source zone for data sync. + .. option:: --fix Besides checking bucket index, will also fix it. diff --git a/src/rgw/rgw_admin.cc b/src/rgw/rgw_admin.cc index a750a9950d5..fc8ed5f9120 100644 --- a/src/rgw/rgw_admin.cc +++ b/src/rgw/rgw_admin.cc @@ -146,6 +146,9 @@ void usage() cout << " metadata sync status get metadata sync status\n"; cout << " metadata sync init init metadata sync\n"; cout << " metadata sync run run metadata sync\n"; + cout << " data sync status get data sync status of the specified source zone\n"; + cout << " data sync init init data sync for the specified source zone\n"; + cout << " data sync run run data sync for the specified source zone\n"; cout << " pool add add an existing pool for data placement\n"; cout << " pool rm remove an existing pool from data placement set\n"; cout << " pools list list placement active set\n"; diff --git a/src/test/cli/radosgw-admin/help.t b/src/test/cli/radosgw-admin/help.t index cb4c4ae9cec..f14f6c65341 100644 --- a/src/test/cli/radosgw-admin/help.t +++ b/src/test/cli/radosgw-admin/help.t @@ -89,6 +89,9 @@ metadata sync status get metadata sync status metadata sync init init metadata sync metadata sync run run metadata sync + data sync status get data sync status of the specified source zone + data sync init init data sync for the specified source zone + data sync run run data sync for the specified source zone pool add add an existing pool for data placement pool rm remove an existing pool from data placement set pools list list placement active set