From: Ilya Dryomov Date: Tue, 27 Aug 2024 18:34:31 +0000 (+0200) Subject: rbd: clarify "rbd {group,} rename" command description X-Git-Tag: testing/wip-mchangir-testing-20240905.063159-main-debug~24^2~1 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=5f064a52707af58fd6007734a768899aeb5a32fc;p=ceph-ci.git rbd: clarify "rbd {group,} rename" command description Make it clearer that, despite a full image or group spec being taken for source and destination, an image or a group can be renamed only within its pool or namespace. Rename across pools or namespaces within the same pool is unsupported. Fixes: https://tracker.ceph.com/issues/67752 Signed-off-by: Ilya Dryomov --- diff --git a/src/test/cli/rbd/help.t b/src/test/cli/rbd/help.t index bee99c51dd1..13ab555e15d 100644 --- a/src/test/cli/rbd/help.t +++ b/src/test/cli/rbd/help.t @@ -51,7 +51,8 @@ group info Show information about a group. group list (group ls) List rbd groups. group remove (group rm) Delete a group. - group rename Rename a group within pool. + group rename Rename a group within its pool or + namespace. group snap create Make a snapshot of a group. group snap info Show information about a group snapshot. group snap list (... ls) List snapshots of a group. @@ -133,7 +134,8 @@ pool init Initialize pool for use by RBD. pool stats Display pool statistics. remove (rm) Delete an image. - rename (mv) Rename image within pool. + rename (mv) Rename an image within its pool or + namespace. resize Resize (expand or shrink) image. snap create (snap add) Create a snapshot. snap limit clear Remove snapshot limit. @@ -1034,7 +1036,7 @@ [--dest-group ] - Rename a group within pool. + Rename a group within its pool or namespace. Positional arguments source group specification @@ -2262,7 +2264,7 @@ [--dest-namespace ] [--dest ] - Rename image within pool. + Rename an image within its pool or namespace. Positional arguments source image specification diff --git a/src/tools/rbd/action/Group.cc b/src/tools/rbd/action/Group.cc index afcc24455f6..d97e120d438 100644 --- a/src/tools/rbd/action/Group.cc +++ b/src/tools/rbd/action/Group.cc @@ -1046,7 +1046,7 @@ Shell::Action action_list( {"group", "list"}, {"group", "ls"}, "List rbd groups.", "", &get_list_arguments, &execute_list); Shell::Action action_rename( - {"group", "rename"}, {}, "Rename a group within pool.", + {"group", "rename"}, {}, "Rename a group within its pool or namespace.", "", &get_rename_arguments, &execute_rename); Shell::Action action_info( {"group", "info"}, {}, "Show information about a group.", diff --git a/src/tools/rbd/action/Rename.cc b/src/tools/rbd/action/Rename.cc index b4954bcbb90..db198d656e2 100644 --- a/src/tools/rbd/action/Rename.cc +++ b/src/tools/rbd/action/Rename.cc @@ -86,8 +86,8 @@ int execute(const po::variables_map &vm, } Shell::Action action( - {"rename"}, {"mv"}, "Rename image within pool.", "", &get_arguments, - &execute); + {"rename"}, {"mv"}, "Rename an image within its pool or namespace.", "", + &get_arguments, &execute); } // namespace rename } // namespace action