ungleich-tools/ceph-mon-create-start

22 lines
457 B
Text
Raw Normal View History

2018-02-15 22:08:24 +00:00
#!/bin/sh
if [ $# -ne 1 ]; then
echo "$0 initial-key-file"
exit 1
fi
fname=$1
ceph-mon --mkfs -i $(hostname) --keyring "$fname" --setuser ceph --setgroup ceph
touch /var/lib/ceph/mon/ceph-$(hostname)/sysvinit
2018-02-15 22:11:29 +00:00
2018-03-08 12:43:26 +00:00
# Fix broken permissions
chown ceph:ceph /var/run/ceph/
2018-02-23 07:52:18 +00:00
# Starting with monit, if available
if [ -e /etc/monit ]; then
/opt/ungleich-tools/monit-ceph-create-start mon.$(hostname)
else
/etc/init.d/ceph start mon.$(hostname)
fi