]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commit
osds: use ceph osd stat instead of ceph status
authorwangxiaotong <wangxiaotong@fiberhome.com>
Sat, 24 Oct 2020 13:59:17 +0000 (21:59 +0800)
committerGuillaume Abrioux <gabrioux@redhat.com>
Tue, 3 Nov 2020 13:32:09 +0000 (14:32 +0100)
commitb4c1f325a891c73fa2a3adc67e527b49f44e06cd
tree4bd9ad201b9c3b45f31278ab01af24a0fe36a483
parent04d47d68fd8d503fcd4e1734c9a3609ffef35dd8
osds: use ceph osd stat instead of ceph status

Improve the checked way of the OSD created checking process.
This replaces the ceph status command by the ceph osd stat command.
The osdmap structure isn't needed anymore.

$ ceph status -f json | wc -c
2001
$ ceph osd stat -f json | wc -c
132
$ time ceph status -f json > /dev/null

real    0m0.563s
user    0m0.526s
sys     0m0.036s
$ time ceph osd stat -f json > /dev/null

real 0m0.457s
user 0m0.411s
sys 0m0.045s

Signed-off-by: wangxiaotong <wangxiaotong@fiberhome.com>
(cherry picked from commit b9cb0f12e9e79600f1a974dd88ba1ed1d833211f)
roles/ceph-osd/tasks/main.yml