]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mon: Abort device health when device not found
authorBenoît Knecht <bknecht@protonmail.ch>
Mon, 6 Dec 2021 08:14:56 +0000 (09:14 +0100)
committerBenoît Knecht <bknecht@protonmail.ch>
Tue, 4 Jan 2022 13:38:32 +0000 (14:38 +0100)
commitc05a3b769dccf5fe839a2150e39d899516469164
treecafbf7d87e7a4332285e59f8dcb511bc11f2e303
parent9c659f228e46591a8edeba85446534a25c260af1
mon: Abort device health when device not found

If `store->get_devname()` returns an empty device name, it means it couldn't
determine the device that backs the monitor DB store directory.

This can happen if `ceph-mon` runs with `PrivateDevices=yes` in systemd, or
within a container where the host `/dev` isn't exposed.

This commit makes sure we abort trying to get the device health at that point,
and return an appropriate error.

Signed-off-by: Benoît Knecht <bknecht@protonmail.ch>
src/mon/Monitor.cc
src/mon/MonitorDBStore.h