Monday, September 12, 2011

VM Autostart on XenServer

Its a good thing I don't need to run VMware, because they are so dependent on a pre-existing Microsoft infrastructure, that I couldn't run it, even if I tried. And I've tried. Of course, I should just go ahead and invest the $3,000 in Microsoft software... just so I can invest a $1,000 in VMware software. Or, I could use Citrix XenServer.

Unfortunately, Citrix is doing everything in their power to ruin their entry level product, based on the philosophy that if they strip enough useful features from their product, eventually people will have no choice but to buy it. I don't know... If I'm going to throw two grand at them, I might as well up the ante and buy VMware.

Or just hack their product. I mean, come on guys... are you even trying?

So, I've got a cluster of XenServers, and I want to start a VM with the host boots. Ah! Upgrade XenServer to enable! Or add the following to the /etc/rc.d/rc.local for all hosts:
xe vm-start name-lable=YourVmName
If the host is the first to boot, it starts the VM. If the host is not the first, it attempts the command, gets a failure message (becuase the VM is in the wrong power state... on), and boots as normal.

And now we give thanks to the command line Gods.

3 comments:

  1. ...or you could run VMWare ESXi which is free. I have ESXi and I'm building out my XenServer (both at home) so far I prefer ESXi because of ease of use but Xen allows creating datastores on USB Storage

    ReplyDelete
  2. I have an ESXi machine, also, but VMware's management solutions require an existing Windows infrastructure. With Citrix's free Xenserver free implementation, I get features that would require over $2,000 with VMware. Having said that... ESXi is by far the dominant product in the real world.

    ReplyDelete
  3. I created a script that will auto-start VM's based on the "autostart" tag which can be set using XenCenter: http://www.raido.be/knowledge-center/blog/detail/xenserver-6-auto-start-vms

    ReplyDelete