HP BL680c XenServer Administrator's Guide 4.1.0 - Page 57

Low-level list commands

Page 57 highlights

Command line interface Lists all of the parameters and their associated values. Unlike the class-list command, this will list the values of 'expensive' fields. • [class]-param-get uuid=uuid param-name=parameter [param-key=key ] Returns the value of a particular parameter. If the parameter is a map, specifying the param-key will get the value associated with that key in the map. If param-key is not specified, or if the parameter is a set, it will return a string representation of the set or map. • [class]-param-set uuid=uuid param=value ... Sets the value of one or more parameters. • [class]-param-add uuid=uuid param-name=parameter [ key=value ...] [param-key=key ] Adds to either a map or a set parameter. If the parameter is a map, add key/value pairs using the 'key=value' syntax. If the parameter is a set, add keys with the 'param-key=key' syntax. • [class]-param-remove uuid=uuid param-name=parameter param-key=key Removes either a key/value pair from a map, or a key from a set. • [class]-param-clear uuid=uuid param-name=parameter Completely clears a set or a map. 5.3.3. Low-level list commands The class-list command lists the objects of type class. By default it will list all objects, printing a subset of the parameters. This behavior can be modified in two ways: it can filter the objects so that it only outputs a subset, and the parameters that are printed can be modified. To change the parameters that are printed, the argument params should be specified as a comma-separated list of the required parameters, e.g.: xe vm-list params=name-label,other-config Alternatively, to list all of the parameters, use the syntax: xe vm-list params=all Note that some parameters that are expensive to calculate will not be shown by the list command. These will be shown as e.g.: allowed-VBD-devices (SRO): In order 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 object that match all of the specified constraints. For example: 51

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107
  • 108

Command line interface
51
Lists all of the parameters and their associated values. Unlike the
class
-list command, this will list the
values of 'expensive' fields.
[class]
-param-get
uuid=
uuid
param-name=
parameter
[param-key=
key
]
Returns the value of a particular parameter. If the parameter is a map, specifying the param-key will get
the value associated with that key in the map. If param-key is not specified, or if the parameter is a set,
it will return a string representation of the set or map.
[class]
-param-set
uuid=
uuid
param=
value
...
Sets the value of one or more parameters.
[class]
-param-add
uuid=
uuid
param-name=
parameter
[
key
=
value
...] [param-key=
key
]
Adds to either a map or a set parameter. If the parameter is a map, add key/value pairs using the
'key=value' syntax. If the parameter is a set, add keys with the 'param-key=key' syntax.
[class]
-param-remove
uuid=
uuid
param-name=
parameter
param-key=
key
Removes either a key/value pair from a map, or a key from a set.
[class]
-param-clear
uuid=
uuid
param-name=
parameter
Completely clears a set or a map.
5.3.3. Low-level list commands
The
class
-list command lists the objects of type
class
. By default it will list all objects, printing a subset of
the parameters. This behavior can be modified in two ways: it can filter the objects so that it only outputs a
subset, and the parameters that are printed can be modified.
To change the parameters that are printed, the argument
params
should be specified as a comma-separated
list of the required parameters, e.g.:
xe vm-list params=name-label,other-config
Alternatively, to list all of the parameters, use the syntax:
xe vm-list params=all
Note that some parameters that are expensive to calculate will not be shown by the list command. These
will be shown as e.g.:
allowed-VBD-devices (SRO): <expensive field>
In order 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
object that match all of the specified constraints. For example: