zookeeper自动部署脚本

#!/bin/bash
echo "start zkServer..."
for i in 129 130 131
do
ssh 192.168.100.$i "source /etc/profile;/root/apps/zookeeper-3.4.5/bin/zkServer.sh start"

done


免密开启

[root@xuniji bin]# ssh-keygen

[root@xuniji bin]# ssh-copy-id 192.168.100.×

[root@xuniji ~]# ssh-copy-id 192.168.100.×

猜你喜欢

转载自blog.csdn.net/qq_39212193/article/details/81013674