]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
initscripts: allow 'user' option, defaults to current user
authorSage Weil <sage@newdream.net>
Thu, 25 Jun 2009 17:22:33 +0000 (10:22 -0700)
committerSage Weil <sage@newdream.net>
Thu, 25 Jun 2009 17:22:33 +0000 (10:22 -0700)
src/ceph_common.sh
src/cosd.ceph.conf

index d3ff3f9decf4f5aaef6be1bb7fe722618354e387..5fee67d2efbbad85c1a3fa1f7b49aafd603a2cca 100644 (file)
@@ -29,8 +29,13 @@ check_host() {
            fi
 
            # we'll need to ssh into that host
-           ssh="ssh root@$host"
-           get_conf dir "$dir" "ssh path" $sections
+           get_conf sshuser "" "user"
+           if [ -z "$sshuser" ]; then
+               ssh="ssh $host"
+           else
+               ssh="ssh $sshuser@$host"
+           fi
+           get_conf dir "$dir" "ssh path"
        fi
     else
        host=$hostname
@@ -47,7 +52,7 @@ do_cmd() {
        ulimit -c unlimited
        bash -c "$1" || { echo "failed: '$1'" ; exit 1; }
     else
-       [ $verbose -eq 1 ] && echo "--- $host# cd $dir ; ulimit -c unlimited ; $1"
+       [ $verbose -eq 1 ] && echo "--- $ssh $2 \"cd $dir ; ulimit -c unlimited ; $1\""
        $ssh $2 "cd $dir ; ulimit -c unlimited ; $1" || { echo "failed: '$ssh $1'" ; exit 1; }
     fi
 }
index a276dc7928bde633e31c5b6786fd39e09ccf4068..fc7246ae038d13ab6d11a0b82e38682235f9b4ef 100644 (file)
@@ -26,7 +26,7 @@
 
 ; ---------------------
 [mds]
-;      debug mds = 20
+       debug mds = 20
        debug ms = 1
 ;      debug journaler = 20
 ;      log dir = /data/ceph4
 
 ; ---------------------
 [osd]
+       user = root
        debug ms = 1
        debug osd = 20
-;      debug filestore = 20
+       debug filestore = 10
 ;      debug journal = 20
        log dir = /data/cosd$id
        osd data = /mnt/osd$id