!/bin/bash
#vim ip.txt server ip
ip_array=$(cat /tmp/ip.txt)
for ip in ${ip_array[*]}
do
scp -P6122 /tmp/test.sh  root@$ip:/tmp/
done