From: Zac Dover Date: Fri, 9 Dec 2022 01:31:07 +0000 (+1000) Subject: doc/rbd: refine "Restoring a Block Device Image" X-Git-Tag: v17.2.6~292^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F49354%2Fhead;p=ceph.git doc/rbd: refine "Restoring a Block Device Image" Refine and add unselectable prompts to "Restoring a Block Device Image" in doc/rbd/rados-rbd-cmds.rst. https://tracker.ceph.com/issues/57001 Signed-off-by: Zac Dover (cherry picked from commit 8fb4edb92d82019065a884d63a71ca68e8c8de6a) --- diff --git a/doc/rbd/rados-rbd-cmds.rst b/doc/rbd/rados-rbd-cmds.rst index 2d541dfef6db..92427a381def 100644 --- a/doc/rbd/rados-rbd-cmds.rst +++ b/doc/rbd/rados-rbd-cmds.rst @@ -224,30 +224,47 @@ For example:: Restoring a Block Device Image ============================== -To restore a deferred delete block device in the rbd pool, execute the -following, but replace ``{image-id}`` with the id of the image:: +To restore a deferred delete block device in the rbd pool, run the +following command but replace ``{image-id}`` with the ID of the image: - rbd trash restore {image-id} +.. prompt:: bash $ -For example:: + rbd trash restore {image-id} - rbd trash restore 2bf4474b0dc51 +For example: -To restore a deferred delete block device in a particular pool, execute -the following, but replace ``{image-id}`` with the id of the image and -replace ``{pool-name}`` with the name of the pool:: +.. prompt:: bash $ - rbd trash restore {pool-name}/{image-id} + rbd trash restore 2bf4474b0dc51 -For example:: +Restoring a Block Device Image in a Specific Pool +------------------------------------------------- + +To restore a deferred delete block device in a particular pool, run the +following command but replace ``{image-id}`` with the ID of the image and +replace ``{pool-name}`` with the name of the pool: + +.. prompt:: bash $ + + rbd trash restore {pool-name}/{image-id} + +For example: + +.. prompt:: bash $ + + rbd trash restore swimmingpool/2bf4474b0dc51 - rbd trash restore swimmingpool/2bf4474b0dc51 + +Renaming an Image While Restoring It +------------------------------------ You can also use ``--image`` to rename the image while restoring it. -For example:: +For example: - rbd trash restore swimmingpool/2bf4474b0dc51 --image new-name +.. prompt:: bash $ + + rbd trash restore swimmingpool/2bf4474b0dc51 --image new-name .. _create a pool: ../../rados/operations/pools/#create-a-pool