Advertisement
Guest User

Untitled

a guest
Jun 29th, 2016
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. for i in $LIST_OF_LINUX_MACHINES
  2. do
  3. ssh $LINUX_MACHINE /var/tmp/restart.sh
  4. done
  5.  
  6. numprocs=25
  7. timeout=5
  8. xargs -P "$numprocs" -J '{}' -n 1 --
  9. perl -e 'alarm shift; exec @ARGV' -- "$timeout"
  10. ssh -nxaq -o ConnectTimeout=5 -o StrictHostKeyChecking=no '{}' /tmp/reboot.sh
  11. <hostnames # if a file; use < <(awk ...) if a script providing per-line info
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement