# !/bin/sh
SEQ=0
for i in $(cat list_all)
do
SEQ=`expr $SEQ +1`
HOSTNAME="$i"
printf "########### ${SEQ} : ${HOSTNAME} ########\n"
sshpass -p password11! ssh -o ConnectTimeout=3 -o StrictHostKeyChecking=no weblogic@${HOSTNAME} /bin/bash <<'EOT'
sudo su
chown weblogic:wasgrp /work/0*.tar
EOT
sshpass -p password11! scp -o StrictHostKeyChecking=no \
weblogic@${HOSTNAME}:/work/sse/0*.tar \
/DATA/mw_script/
done
|