]> git.proxmox.com Git - pve-manager.git/commit
ceph osd: return PGs per OSD and show in UI
authorAaron Lauterer <a.lauterer@proxmox.com>
Tue, 14 Feb 2023 08:13:47 +0000 (09:13 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 15 Feb 2023 09:16:50 +0000 (10:16 +0100)
commitc4368cf6d6ade5cc3cb48544180ea20afd0c149d
tree559777f76b61d028dc8d17c67161e8047bbd245a
parent93c425e1096bb963c91587263b7392dbdbf9a0bc
ceph osd: return PGs per OSD and show in UI

By switching from 'ceph osd tree' to the 'ceph osd df tree' mon API
equivalent , we get the same data structure with more information per
OSD. One of them is the number of PGs stored on that OSD.

The number of PGs per OSD is an important number, for example when
trying to figure out why the performance is not as good as expected.
Therefore, adding it to the OSD overview visible by default should
reduce the number of times, one needs to access the CLI.

Comparing runtime cost on a 3 node ceph cluster with 4 OSDs each doing 50k
iterations gives:

               Rate osd-df-tree    osd-tree
osd-df-tree  9141/s          --        -25%
osd-tree    12136/s         33%          --

So, while definitively a bit slower, but it's still in the µs range,
and as such below HTTP in TLS in TCP connection setup for most users,
so worth the extra useful information.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
 [ TL: slight rewording of subject and add benchmark data ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
PVE/API2/Ceph/OSD.pm
www/manager6/ceph/OSD.js