#!/bin/bash
if [ $# -lt 1 ]; then
echo no args
exit;
fi
echo ----xcall $arg1 from localhost----
$@
echo
for((i=2;i<=3;i++));
do
echo ----xcall $arg1 from centos$i ----;
ssh centos$i $@
echo
done
Linux 同时在多个服务器中执行命令
最新推荐文章于 2022-11-17 14:49:32 发布