From: Josh Durgin Date: Thu, 3 Nov 2011 22:45:43 +0000 (-0700) Subject: rbd: document --order and list required args where they're necessary X-Git-Tag: v0.39~162 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=256ac72abc54504d613f2513fd8ac0a6a1e722fa;p=ceph.git rbd: document --order and list required args where they're necessary Signed-off-by: Josh Durgin --- diff --git a/src/rbd.cc b/src/rbd.cc index d0c3906e7782d..97573894ca14d 100644 --- a/src/rbd.cc +++ b/src/rbd.cc @@ -66,10 +66,8 @@ void usage() << " [pool-name] list rbd images\n" << " info <--snap=name> [image-name] show information about image size,\n" << " striping, etc.\n" - << " create [image-name] create an empty image (requires size\n" - << " param)\n" - << " resize [image-name] resize (expand or contract) image\n" - << " (requires size param)\n" + << " create <--order=bits> [--size MB] [name] create an empty image\n" + << " resize [--size MB] [image-name] resize (expand or contract) image\n" << " rm [image-name] delete an image\n" << " export <--snap=name> [image-name] [path] export image to file\n" << " import [path] [dst-image] import image from file (dest defaults\n" @@ -94,6 +92,8 @@ void usage() << " --dest-pool destination pool name\n" << " --path path name for import/export (if not specified)\n" << " --size size parameter for create and resize commands\n" + << " --order the object size in bits, such that the objects\n" + << " are (1 << order) bytes. Default is 22 (4 MB).\n" << "\n" << "For the map command:\n" << " --user rados user to authenticate as\n" diff --git a/src/test/cli/rbd/help.t b/src/test/cli/rbd/help.t index 6c86e7ea6f2a7..2e21bef1fd37f 100644 --- a/src/test/cli/rbd/help.t +++ b/src/test/cli/rbd/help.t @@ -4,10 +4,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -32,6 +30,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as diff --git a/src/test/cli/rbd/invalid-snap-usage.t b/src/test/cli/rbd/invalid-snap-usage.t index c97d6cb2e2be8..d5e062053f2eb 100644 --- a/src/test/cli/rbd/invalid-snap-usage.t +++ b/src/test/cli/rbd/invalid-snap-usage.t @@ -5,10 +5,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -33,6 +31,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -45,10 +45,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -73,6 +71,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -85,10 +85,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -113,6 +111,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -125,10 +125,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -153,6 +151,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -165,10 +165,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -193,6 +191,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -205,10 +205,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -233,6 +231,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -245,10 +245,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -273,6 +271,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -285,10 +285,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -313,6 +311,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as @@ -325,10 +325,8 @@ [pool-name] list rbd images info <--snap=name> [image-name] show information about image size, striping, etc. - create [image-name] create an empty image (requires size - param) - resize [image-name] resize (expand or contract) image - (requires size param) + create <--order=bits> [--size MB] [name] create an empty image + resize [--size MB] [image-name] resize (expand or contract) image rm [image-name] delete an image export <--snap=name> [image-name] [path] export image to file import [path] [dst-image] import image from file (dest defaults @@ -353,6 +351,8 @@ --dest-pool destination pool name --path path name for import/export (if not specified) --size size parameter for create and resize commands + --order the object size in bits, such that the objects + are (1 << order) bytes. Default is 22 (4 MB). For the map command: --user rados user to authenticate as