From: Waad AlKhoury Date: Fri, 29 Oct 2021 14:38:11 +0000 (+0200) Subject: doc/mgr: Add cli api documentation X-Git-Tag: v16.2.8~197^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=0ea1b07538954bc87d77b43742a4d99deae1ff23;p=ceph.git doc/mgr: Add cli api documentation Signed-off-by: Waad AlKhoury --- diff --git a/doc/mgr/cli_api.rst b/doc/mgr/cli_api.rst new file mode 100644 index 000000000000..81a99ae44ac1 --- /dev/null +++ b/doc/mgr/cli_api.rst @@ -0,0 +1,39 @@ +CLI API Commands Module +======================= + +The CLI API module exposes most ceph-mgr python API via CLI. Furthermore, this API can be +benchmarked for further testing. + +Enabling +-------- + +The *cli api commands* module is enabled with:: + + ceph mgr module enable cli_api + +To check that it is enabled, run:: + + ceph mgr module ls | grep cli_api + +Usage +-------- + +To run a mgr module command, run:: + + ceph mgr cli + +For example, use the following command to print the list of servers:: + + ceph mgr cli list_servers + +List all available mgr module commands with:: + + ceph mgr cli --help + +To benchmark a command, run:: + + ceph mgr cli_benchmark + +For example, use the following command to benchmark the command to get osd_map:: + + ceph mgr cli_benchmark 100 10 get osd_map diff --git a/doc/mgr/index.rst b/doc/mgr/index.rst index 50754a5e2b54..66fa19f86394 100644 --- a/doc/mgr/index.rst +++ b/doc/mgr/index.rst @@ -47,3 +47,4 @@ sensible. Rook module MDS Autoscaler module NFS module + CLI API Commands module