From d00d1b52d50b5575d918c3be7b7a8249ef31f0a8 Mon Sep 17 00:00:00 2001 From: Zac Dover Date: Mon, 26 Aug 2024 06:03:34 +1000 Subject: [PATCH] doc/cephadm: how to get exact size_spec from device Add instructions for retrieving the exact size of block devices. Fixes: https://tracker.ceph.com/issues/66754 Signed-off-by: Zac Dover --- doc/cephadm/services/osd.rst | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/doc/cephadm/services/osd.rst b/doc/cephadm/services/osd.rst index 3ed091a06a5..9c0b4d2b495 100644 --- a/doc/cephadm/services/osd.rst +++ b/doc/cephadm/services/osd.rst @@ -84,6 +84,39 @@ information about interacting with these LEDs, refer to :ref:`devices`. The current release of `libstoragemgmt`_ (1.8.8) supports SCSI, SAS, and SATA based local disks only. There is no official support for NVMe devices (PCIe) +Retrieve Exact Size of Block Devices +==================================== + +Run a command of the following form to discover the exact size of a block +device. The value returned here is used by the orchestrator when comparing high +and low values: + +.. prompt:: bash # + + cephadm shell ceph-volume inventory --format json | jq .sys_api.human_readable_size + +The exact size in GB is the size reported in TB, multiplied by 1000. + +Example +------- +The following provides a specific example of this command based upon the +general form of the command above: + +.. prompt:: bash # + + cephadm shell ceph-volume inventory /dev/sdc --format json | jq .sys_api.human_readable_size + +:: + + "3.64 TB" + +This means that the exact device size is 3.64 * 1000, or 3640GB. + +This procedure was developed by Frédéric Nass. See `this thread on the +[ceph-users] mailing list +`_ +for discussion of this matter. + .. _cephadm-deploy-osds: Deploy OSDs -- 2.39.5