From e6d47c2092c352b0c9a0a72caee8638889577021 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Tue, 27 Sep 2011 22:07:58 -0300 Subject: Implementing other ssh frontends --- share/hydra/mass | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) 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 -- cgit v1.2.3