]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
init-ceph: fix run dir
authorSage Weil <sage@inktank.com>
Thu, 7 Mar 2013 01:09:51 +0000 (17:09 -0800)
committerSage Weil <sage@inktank.com>
Thu, 7 Mar 2013 01:09:58 +0000 (17:09 -0800)
Signed-off-by: Sage Weil <sage@inktank.com>
src/init-ceph.in

index 101ccab28c033ebba89c82c8b956fc6806afce0d..5c04dd036f5e5429db0533a65cdd361ab5fbe3be 100644 (file)
@@ -245,6 +245,8 @@ for name in $what; do
        lockfile=""
     fi
 
+    get_conf asok "$RUN_DIR/ceph-$type.$id.asok" "admin socket"
+
     case "$command" in
        start)
             # Increase max_open_files, if the configuration calls for it.
@@ -327,7 +329,6 @@ for name in $what; do
                # via mkcephfs, which is fine too; there is no harm
                # in creating these keys.
                get_conf mon_data "/var/lib/ceph/mon/ceph-$id" "mon data"
-               get_conf asok "/var/run/ceph-$type.$id.asok" "admin socket"
                if [ "$mon_data" = "/var/lib/ceph/mon/ceph-$id" -a "$asok" = "/var/run/ceph/ceph-mon.$id.asok" ]; then
                    echo Starting ceph-create-keys on $host...
                    cmd2="$SBINDIR/ceph-create-keys -i $id 2> /dev/null &"
@@ -354,7 +355,6 @@ for name in $what; do
 
        status)
            if daemon_is_running $name ceph-$type $id $pid_file; then
-               get_conf asok "$RUN_DIR/ceph-$type.$id.asok" "admin socket"
                echo -n "$name: running "
                do_cmd "$BINDIR/ceph --admin-daemon $asok version 2>/dev/null" || echo unknown
             elif [ -e "$pid_file" ]; then