xe vm-list params=all

Note that some parameters that are expensive to calculate will not be shown by the list command. These parameters will be shown as, for example:

allowed-VBD-devices (SRO): <expensive field>

To obtain these fields, use either the command <class>-param-list or <class>-param-get

To filter the list, the CLI will match parameter values with those specified on the command-line, only printing objects that match all of the specified constraints. For example:

xe vm-list HVM-boot-policy="BIOS order" power-state=halted

This command will only list those VMs for which both the field power-statehas the value halted, and for which the field HVM-boot-policyhas the value BIOS order.

It is also possible to filter the list based on the value of keys in maps, or on the existence of values in a set. The syntax for the first of these is map-name:key=value, and the second is set-name:contains=value

For scripting, a useful technique is passing --minimalon the command line, causing xe to print only the first field in a comma-separated list. For example, the command xe vm-list--minimalon a XenServer host with three VMs installed gives the three UUIDs of the VMs, for example:

a85d6717-7264-d00e-069b-3b1d19d56ad9,aaa3eec5-9499-bcf3-4c03-af10baea96b7, \ 42c044de-df69-4b30-89d9-2c199564581d

xe Command Reference

This section provides a reference to the xe commands. They are grouped by objects that the commands address, and listed alphabetically.

Appliance Commands

Commands for creating and modifying VM appliances (also known as vApps). For more information on vApps, see the XenServer Virtual Machine Installation Guide.

Appliance Parameters

Appliance commands have the following parameters

Parameter Name

Description

Type

 

 

 

uuid

appliance uuid

required

 

 

 

name-description

appliance description

optional

 

 

 

paused

 

optional

 

 

 

force

force shutdown

optional

 

 

 

appliance-assert-can-be-recovered

appliance-assert-can-be-recovered uuid=<appliance-uuid>database:vdi-uuid=<vdi-uuid>Tests whether storage is available to recover this VM appliance/vApp.

appliance-create

appliance-createname-label=<name-label>[name-description=<name-description>]

116

Page 134
Image 134
Citrix Systems 6 manual Xe Command Reference, Appliance Commands, Appliance Parameters, Appliance-assert-can-be-recovered