Created
May 17, 2014 22:58
-
-
Save rtomaszewski/d0faea99eaf90895d8fd to your computer and use it in GitHub Desktop.
spin up a vm in xenserver ( http://rtomaszewski.blogspot.co.uk/2014/05/using-xe-how-to-boot-vm-in-xenserver.html )
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
set -x | |
template=`xe template-list name-label="Ubuntu Lucid Lynx 10.04 (64-bit)" --minimal` | |
vm=`xe vm-install template=$template new-name-label=vm-label` | |
network=`xe network-list bridge=xenbr0 --minimal` | |
vif=`xe vif-create vm-uuid=$vm network-uuid=$network device=0` | |
xe vm-param-set uuid=$vm other-config:install-repository=http://archive.ubuntu.com/ubuntu | |
xe vm-param-set uuid=$vm PV-args="auto-install/enable=true interface=auto netcfg/dhcp_timeout=600 hostname=vm-host-name domain=mydomain.is.best" | |
xe vm-start uuid=$vm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment