Skip to content

Instantly share code, notes, and snippets.

@utarn
Last active December 19, 2018 05:01
Show Gist options
  • Save utarn/0085868a8fd5534f62fbd570cc19466a to your computer and use it in GitHub Desktop.
Save utarn/0085868a8fd5534f62fbd570cc19466a to your computer and use it in GitHub Desktop.
CLOUD COMPUTING CLASS: script to bulk start
for i in $(seq -w $1 $2)
do
num=$(printf %02d $i)
VMID=`vim-cmd vmsvc/getallvms |grep CentOS7-$num | cut -f1 -d' '`
vim-cmd vmsvc/power.on $VMID
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment