Setting the XenServer to allow VM Auto-Start

Setting pool(s) to Auto-Start

Gather the UUID’s of the pools you wish to auto-start. To get the list type xe pool-list:

     [root@xenserver]# xe pool-list
     uuid ( RO)                : a70d9fa9-27be-fd61-dafe-51615d7391bf
               name-label ( RW): 
         name-description ( RW): 
                   master ( RO): 0c522bd5-077a-4f45-a85d-c3d17867c51e
               default-SR ( RW): 8d52811f-ad43-9e7e-30b6-28c9c0a3e8b2

Copy the UUID of the pool (if you have just one server, it will still have a pool UUID) and type the following command to allow auto-start:

    [root@xenserver]# xe pool-param-set uuid=a70d9fa9-27be-fd61-dafe-51615d7391bf other-config:auto_poweron=true

Setting the Virtual Machines to Auto-Start

Gather the UUID’s of the vm(s) you want to auto-start by typing xe vm-list.
This generates a list of vms in your pool or server and their associated UUID’s.

Then copy the UUID of the vms you want to auto-start, and type the following command for each Virtual Machine to auto-start: xe vm-param-set uuid=UUID other-config:auto_poweron=true

Setting the vApp to Auto-Start

You can also try to start your vms using vApp, but its more like a workaround. To do that follow these simple steps:

  1. Create vApp.
  2. Choose vms to vApp.
  3. Choose boot order and delays between starts.
  4. Use xe appliance-list name-label="name-vapp" to get uuid of vApp.
  5. Use vim /etc/rc.local to open rc.local file.
  6. At the end of the file past:
    sleep 40 xe appliance-start uuid=uuid-vapp
  7. Save file, reboot XenServer.

Now your vApp will start with XenServer and will start vms inside in chosen order.