Created
February 21, 2014 09:59
-
-
Save anonymous/9131673 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/datastore_mad/remotes/ceph/cp b/src/datastore_mad/remotes/ceph/cp | |
index 505ce23..d4db533 100755 | |
--- a/src/datastore_mad/remotes/ceph/cp | |
+++ b/src/datastore_mad/remotes/ceph/cp | |
@@ -141,7 +141,11 @@ REGISTER_CMD=$(cat <<EOF | |
EOF | |
) | |
-ssh_exec_and_log "$DST_HOST" "$REGISTER_CMD" \ | |
- "Error registering $RBD_SOURCE in $DST_HOST" | |
+if [ "$DST_HOST" = `hostname` ]; then | |
+ exec_and_log "$REGISTER_CMD" "Error registering $RBD_SOURCE in $DST_HOST" | |
+else | |
+ ssh_exec_and_log "$DST_HOST" "$REGISTER_CMD" \ | |
+ "Error registering $RBD_SOURCE in $DST_HOST" | |
+fi | |
echo "$RBD_SOURCE" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment