]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: fixed "unrecognized arg" error when using "radosgw-admin zone rm". 30172/head
authorroot <root@devel.localdomain>
Mon, 2 Sep 2019 03:23:45 +0000 (11:23 +0800)
committerNathan Cutler <ncutler@suse.com>
Thu, 5 Sep 2019 09:31:40 +0000 (11:31 +0200)
Signed-off-by: Hongang Chen <c744402859@gmail.com>
Author:    root <root@devel.localdomain>
Date:      Mon Sep 2 11:23:45 2019 +0800
(cherry picked from commit 848f1de0d0b6c8aeacfa1c2840f54f6824d8cfb5)

doc/radosgw/multisite.rst
src/rgw/rgw_admin.cc

index 181718bd5849edbca16ca1aaa8df58b4d93f32e2..c973ee1ff5eb0c74d4b448e3c6b770ae6a0af748 100644 (file)
@@ -224,7 +224,7 @@ the default zone group first.
 
     # radosgw-admin zonegroup remove --rgw-zonegroup=default --rgw-zone=default
     # radosgw-admin period update --commit
-    # radosgw-admin zone delete --rgw-zone=default
+    # radosgw-admin zone rm --rgw-zone=default
     # radosgw-admin period update --commit
     # radosgw-admin zonegroup delete --rgw-zonegroup=default
     # radosgw-admin period update --commit
@@ -412,7 +412,7 @@ Delete the default zone if needed.
 
 ::
 
-    # radosgw-admin zone delete --rgw-zone=default
+    # radosgw-admin zone rm --rgw-zone=default
 
 Finally, delete the default pools in your Ceph storage cluster if
 needed.
@@ -1285,7 +1285,7 @@ Next, delete the zone. Execute the following:
 
 ::
 
-    # radosgw-admin zone delete --rgw-zone<name>
+    # radosgw-admin zone rm --rgw-zone<name>
 
 Finally, update the period:
 
index 81fd13ef55c3e0ebc84c12b48f470ae5a3eed483..3a50426f5149d353d25d7f00c75b384277f2f465 100644 (file)
@@ -825,7 +825,7 @@ static int get_cmd(const char *cmd, const char *prev_cmd, const char *prev_prev_
     if (strcmp(cmd, "list") == 0)
       return OPT_ZONE_PLACEMENT_LIST;
   } else if (strcmp(prev_cmd, "zone") == 0) {
-    if (strcmp(cmd, "delete") == 0)
+    if (match_str(cmd, "rm", "delete"))
       return OPT_ZONE_DELETE;
     if (strcmp(cmd, "create") == 0)
       return OPT_ZONE_CREATE;