summaryrefslogtreecommitdiff
path: root/src/mkcephfs.in
diff options
context:
space:
mode:
authorTommi Virtanen <tommi.virtanen@dreamhost.com>2011-04-25 10:21:39 -0700
committerTommi Virtanen <tommi.virtanen@dreamhost.com>2011-04-25 10:21:39 -0700
commit21504a06dcc0e3d3bccab1fe183de2b1bd9fe844 (patch)
treebe886645610b2b55ac600d40eebd5b713dde4587 /src/mkcephfs.in
parent3207c5df646d29a060c199335a2aee56f4fe7409 (diff)
downloadceph-21504a06dcc0e3d3bccab1fe183de2b1bd9fe844.tar.gz
mkcephfs: Fail if a mon has no address set.
Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
Diffstat (limited to 'src/mkcephfs.in')
-rw-r--r--src/mkcephfs.in4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mkcephfs.in b/src/mkcephfs.in
index 5362e94e166..11f96a2daf4 100644
--- a/src/mkcephfs.in
+++ b/src/mkcephfs.in
@@ -182,6 +182,10 @@ if [ $preparemonmap -eq 1 ]; then
for name in $mons; do
id=`echo $name | cut -c 4- | sed 's/^\\.//'`
get_conf addr "" "mon addr"
+ if [ -z "$addr" ]; then
+ echo "$0: monitor $name has no address defined." 1>&2
+ exit 1
+ fi
args=$args" --add $id $addr"
done