ceph-mon is installed with the 'ceph' package so we can't just check if `ceph-mon` is available on a system

Instead, check if the current hostname is list as an initial monitor.
This commit is contained in:
gardouille 2015-04-16 16:46:55 +02:00
parent 1747f3c2eb
commit 3b7c342120
1 changed files with 4 additions and 1 deletions

View File

@ -109,7 +109,10 @@ fi
### FI ZFS
### IF Ceph Monitor
if [ $(which ceph-mon) ]; then
#if [ $(which ceph-mon) ]; then
#ceph-mon is installed with the 'ceph' package
#so we can't just check if `ceph-mon` is available on a system
if (grep "mon_initial_members.*$(hostname)" /etc/ceph/*.conf > /dev/null); then
MSG=$(process_info "ceph-mon" '')
MSG=$(service_info "6789" "${MSG}")
printf '%b' "\n${MSG}"