summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xshare/hydra/mass22
1 files changed, 21 insertions, 1 deletions
diff --git a/share/hydra/mass b/share/hydra/mass
index d7b466c..401d1af 100755
--- a/share/hydra/mass
+++ b/share/hydra/mass
@@ -6,6 +6,7 @@
# Issue commands with pssh
# See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=549117
function mass_pssh {
+ echo "Issuing $COMMAND on multiple nodes..."
hydra_set_tmpfile nodes
hydra $HYDRA nodes > $TMPWORK
parallel-ssh -h $TMPWORK -p 4 $COMMAND
@@ -21,6 +22,24 @@ function mass_loop {
done
}
+# Issue commands with dish
+function mass_dish {
+ echo "Issuing $COMMAND on multiple nodes..."
+ hydra_set_tmpfile nodes
+ hydra $HYDRA nodes > $TMPWORK
+ dish -f -p /dev/null -e "$COMMAND" -g $TMPWORK
+ hydra_unset_tmpfile $TMPWORK
+}
+
+# Issue commands with mussh
+function mass_mussh {
+ echo "Issuing $COMMAND on multiple nodes..."
+ hydra_set_tmpfile nodes
+ hydra $HYDRA nodes > $TMPWORK
+ mussh -b -H $TMPWORK -c "$COMMAND"
+ hydra_unset_tmpfile $TMPWORK
+}
+
# Load
source $APP_BASE/lib/hydra/functions || exit 1
hydra_config_load
@@ -42,4 +61,5 @@ elif [ "$BASENAME" == "mass-web" ]; then
fi
# Execute commands in hosts
-mass_loop $COMMAND
+BASEDIR="/tmp"
+mass_mussh $COMMAND