forked from accelazh/ceph-allinone
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig-all.sh
executable file
·58 lines (48 loc) · 1.65 KB
/
config-all.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#!/bin/bash
##########################
# This file configures ceph,
# according to the configuration you
# set in config.sh
#
# WARNING: it will earse oriiginal
# ceph configuration data files
#
# after configuration, service will
# already be started
##########################
BASEDIR=$(dirname $0)
# make sure we have a clean start
${BASEDIR}/purge-all.sh
${BASEDIR}/gen-user.sh
${BASEDIR}/gen-conf.sh
${BASEDIR}/gen-keyrings.sh
${BASEDIR}/init-mon.sh
# to config OSD we need monitors running
${BASEDIR}/start-mon.sh
${BASEDIR}/test-mon.sh
if [ $? != 0 ]; then
echo "Monitor tests failed. Exiting configuration process. You can use purge-all.sh to cleanup."
exit 1
fi
${BASEDIR}/init-osd.sh
${BASEDIR}/start-osd.sh
${BASEDIR}/test-osd.sh
if [ $? != 0 ]; then
echo "OSD tests failed. Exiting configuration process. You can use purge-all.sh to cleanup."
exit 1
fi
${BASEDIR}/test-all.sh
if [ $? != 0 ]; then
echo "Final tests failed. Exiting configuration process. You can use purge-all.sh to cleanup."
exit 1
fi
echo ""
echo "###########################################################################"
echo "The configuration has succeeded! Services already started."
echo "Use connect.py to get into ceph command line."
echo "Use start-all.sh, stop-all, restart-all to manage ceph services."
echo "Use test-all.sh to check whether services are working normally."
echo "Use purge-all.sh to remove all and cleanup."
echo "Use config-all.sh again (don't need purge-all.sh before it) to get a fresh clean re-install. It includes tests to ensure services are properly installed."
echo "###########################################################################"
echo ""