Guest User

Untitled

a guest
Oct 21st, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. for i in $(consul members | grep awk {'print $2'} | cut -d ":" -f1) ; do sshpass -p $PASSWORD ssh -oStrictHostKeyChecking=no -q root@$i "hostname && yum clean all && yum -y update consul && systemctl restart consul.service" ; done
  2.  
  3. consul members | ... awk {'print $2'} | cut -d ":" -f1 |
  4. parallel -j 10 sshpass -p "$PASSWORD" ssh -oStrictHostKeyChecking=no -q root@{} "hostname && yum clean all && yum -y update consul && systemctl restart consul.service"
  5.  
  6. pssh -h <(consul members | grep awk {'print $2'} | cut -d ":" -f1) -o /tmp/update-consul-servers -i "yum clean all && yum -y update consul && systemctl restart consul.service"
Add Comment
Please, Sign In to add comment