Moab Viewpoint
Node Management

Node Management

Node Management table
Click to enlarge

The Node Management page works with the VM Management Page and consists of a table grid that displays nodes with drill through capability for viewing VMs, a set of buttons above the table for operating on one or more rows selected in the table, and configurable panels for displaying individual nodes in detail. All these components can be configured in nodes.xml. The format of the related XML is give below.

<nodes>
  ...
  <node-management>
    <controls>
      ...
    </controls>
    <table>
      ...
    </table>
    <node-details>
      ...
    </node-details>
    <vm-details>
      ...
    </vm-details>
  </node-management>
  ...
</nodes>

Configuring the Table

The Node Management table can be configured at the column-level to show different attributes for nodes. The relevant XML section for configuring the table is nodes > node-management > table > fields. Each child element of the fields element corresponds to a single column, and the columns will appear in the same order that the child elements are specified. The name of each element corresponds to the type of the column. This type knows how to extract a piece of information from a table record to display in the column, and also contains sensible defaults for display options of the column. The currently allowed field types are:

  • <access-policy>
  • <alias>
  • <architecture>
  • <disk-available>
  • <disk-total>
  • <disk-utilized>
  • <features>
  • <hypervisor-type>
  • <id>
  • <ip-address>
  • <link-id>
  • <load>
  • <memory-available>
  • <memory-total>
  • <memory-utilized>
  • <os>
  • <pending-actions>
  • <power>
  • <power-policy>
  • <priority>
  • <processors-available>
  • <processors-total>
  • <processors-utilized>
  • <state>
  • <status>
  • <substate>
  • <type>
  • <vlans>
  • <vm-link> - Formatted with number of VMs on hypervisor, but also as a link to VM Management Page with appropriate filter. Should be used in the table for linking
  • <vm-count> - Formatted to return string value of number of VMs on hypervisor

All field types have these attributes:

  • primary (optional) - Default is "false". Specifies whether this field forms part or all of primary key for the table records.
  • visible (optional) - Default is "true". Specifies whether the column should displayed or be hidden.
  • width (optional) - Specifies the width in pixels of the column.

All field types have this child element:

  • <title> (optional) - The name of the column to be displayed to the user.

In addition to the above fields, the <table> element supports a special kind of column named "composite". The composite column allows you to display a value based on the basic fields listed above by using the value decider framework. Each field can be accessed with <component> elements. You must specify a width and a title for the <component> element. The contents of the <value> element constitute the value decider portion that determines the form of the column values. The basic structure of a <composite> element is below:

<composite width="100">
  <title>Column title</title>
  <value>
    ... 
  </value>
</composite>

An example of a composite value is one that displays both the available disk space and the total configured disk space on nodes and VMs in gigabytes. Disk values are reported directly as given by Moab. If Moab is reporting disk values in megabytes, you could configure the composite value as shown in the example below. This example displays a column value of the form <disk available in GB> / <disk total in GB>.

<composite width="75">
  <title>Disk (GB)</title>
  <value>
    <calculate operation="append-in-order">
      <value order="1">
        <calculate operation="double-to-string" format="#.#">
          <calculate binary-operation="multiply">
            <first>
              <component id="disk-available"/>
            </first>
            <second>.0001</second>
          </calculate>
        </calculate>
      </value>
      <value order="2"> / </value>
      <value order="3">
        <calculate operation="double-to-string" format="#.#">
          <calculate binary-operation="multiply">
            <first>
              <component id="disk-total"/>
            </first>
            <second>.0001</second>
          </calculate>
        </calculate>
      </value>
    </calculate>
  </value>
</composite>

An example node table configuration is given below:

<node-management>
  <table>
    <fields>
      <id primary="true" width="150">
        <title>Name</title>
      </id>
      <status/>
      <power/>
      <pending-actions width="100"/>
      <os width="60">
        <title>Op. Sys.</title>
      </os>
      <vlans>
        <title>VLAN</title>
      </vlans>
      <load/>
    </fields>
  </table>
</node-management>

Customizing State Values

The values reported by the state, substate, and status fields can be customized using the localization framework (see Tailoring Semantics to Specific Markets or Customers). Add the value to be replaced to the market.properties configuration file, followed by an '=,' and then the value that will replace it. For example, adding Drained = Admin down will cause "Admin Down" to show up in the Node Management table if the status "Drained" is reported for a node.

Primary Keys

In order for many features of the Node Management page to work properly, you must configure at least one field to be a primary key field. We strongly recommend creating an id field as the sole primary key field. You can make this field invisible if you don't want users to see it.

Filtering the Table

The following table filters are supported:

  • disk-available: This filters nodes based on available disk.
  • disk-total: This filters nodes based on total or configured disk.
  • disk-utilized: This filters nodes based on their currently utilized disk. Specifically, the filter matches a server if the specified filter value is contained in the utilized disk value for the server. The search is done lexicographically. Some examples:
    • the filter value 6 matches a server with a utilized disk value of 6, 16, 61, or 123456789.
    • The filter value 0 does not match a server with a utilized disk of 12.
  • id: This filters nodes based on their names. The filter matches if the filter value is equal to the server's name or if the server's name contains the filter value inside it. The filter is case insensitive. Examples are:
    • The filter value n1 will match servers named n1, n10, n123, fan1, or fan12.
    • The filter value n1 will not match a server named n21.
  • ip-address: This filters nodes based on their current IP address. The search is done the same as with server name, and the entire IP address is treated as if it were a name.
  • load: This filters nodes based on their current load. The search is done the same as with utilized disk.
  • memory-available: This filters nodes based on available memory.
  • memory-total: This filters nodes based on total memory.
  • memory-utilized: This filters nodes based on their currently utilized memory. The search is done the same as with utilized disk.
  • os: This filters nodes based on their operating system. The search is done the same as with server name.
  • power: This filters nodes based on their power status. The search is done the same as with server name.
  • processors-available: This filters nodes based on available processors.
  • processors-total: This filters nodes based on configured processors.
  • processors-utilized. This filters nodes based on their currently utilized processors. The search is done the same as with utilized disk.
  • state. This filters nodes based on their current state. The search is done the same as with server name.
  • substate: Filters based on the substate of a VM.
  • vlan. This filters nodes based on their VLAN. The search is done the same as with server name.

Controlling Node Visibility

You can control the way nodes are displayed using Moab. If nodes are set up using the variable "VP_IS_VISIBLE=false", they will not be displayed on the Node Management page. If the variable is set to anything other than "false", or if the variable is not present in a node, the node will be displayed normally, which is the default.

Table Buttons

Control panel

The above-table controls perform actions based on items like the currently selected table records. The above-table buttons are configured in the <controls> child element of <node-management>. Supported elements are listed below. Note that some buttons are only valid for a particular record type (node or VM). Buttons disable themselves when their surrounding context is invalid such as if the button requires a selected record but no table record is selected, or if the type of the selected record doesn't apply to the button.

  • <power-off> - Powers off the currently selected nodes.
  • <power-on> - Powers on the currently selected nodes.
  • <refresh> - Refreshes the table and any open details panel.
  • <reprovision> - Reprovisions all selected nodes.
  • <show-pending-actions> - Redirects to the pending actions page for the currently selected node.
  • <modify-host-reservations> - Displays a popup listing all host-based reservations that include the selected node in their host expression. Users can then remove reservations from the node by either shrinking them or by deleting them if they exist only on the selected node.
  • <remove-admin-reservations> - Removes all host-based user reservations from the selected nodes. If these reservations would then become empty, they are deleted instead.

In addition to specifying an action type via the element's name, you can configure the display of the button using any of the following attributes.

  • image-url (optional) - Path to an icon that will be used to display the button.
  • label (optional) - Text to be displayed either on the button or, if an image is specified, to its right side.
  • tooltip (optional) - Tool-tip to be displayed on the button when the mouse hovers over it.

You can also specify the permission access for each button with the <permissions> child element. This element can contain a sequence of <permission> elements that specifiy a Viewpoint permission a user needs in order to see and use the button. An example permissions configuration might be:

<power-off>
  <permissions>
    <permission name="node.update"/>
  </permissions>
</power-off>

In this example, a user can use the power-off button only if they have the node.update permission.

Details Panel

The Node management page contains a panel for displaying a node in detail. These sections are configured in the nodes > node-management > details element. These panels currently allow one to configure a title, a set of controls, and a list of sections to display information in. The title can contain field references that will be replaced with the value of the field of the current object being viewed. Allowable fields are those available for the node table. Most of these fields are specified by prefixing a field name with $ and optionally wrapping it in curly brackets. Examples include $id, ${name}, and $cpu. In addition, one can display a variable in the title using the map variable syntax, which suffixes the field name with a key enclosed in square brackets. For example, the reference $variable[VLAN] would be substituted with the value of the variable "VLAN" in the title.

Buttons

Each details panel contains a buttons section that has the same structure as the above-table buttons. They actually support an arbitrary menu structure, but that structure is more likely to be used in the details panel. That is, in addition to the button elements described above, a submenu can be created with a menu element that itself contains child elements. Arbitrarily nested menus can thus be created. Besides containing child elements, a menu element can also specify a boolean attribute vertical, which defaults to "true", that specifies the menu's layout direction. Furthermore, a menu itself can have permissions just like a button. If a user doesn't have permissions to view a menu, then he or she will not see the menu or any of its sub-elements.

The scope of a details panel button is the panel itself. Because of this, buttons that require a record to be selected in the node table, if they were placed above the table, treat the record displayed in the details panel as the selected record. Also, the refresh button refreshes only the details panel.

An example node buttons configuration is:

...
<node-details>
  <controls>
    <menu vertical="true" image-url="images/vm-menu.png" tooltip="Perform VM operations on this hypervisor">
      <create-vm image-url="images/vm-create-green.png" tooltip="Create a new VM" label="Create VM..."/>
      <destroy-all-vms image-url="images/vm-destroy.png" tooltip="Destroy all VMs on this hypervisor" label="Destroy VMs"/>
      <reprovision-all-vms image-url="images/reprovision.png" tooltip="Reprovision all VMs on this hypervisor" label="Reprovision VMs..."/>
      <migrate-all-vms image-url="images/migrate.gif" tooltip="Migrate VMs away from this hypervisor" label="Migrate VMs..."/>
      <start-all-vms image-url="images/play.png" tooltip="Starts all VMs on this hypervisor" label="Start VMs"/>
      <stop-all-vms image-url="images/stop.png" tooltip="Stops all VMs on this hypervisor" label="Stop VMs"/>
    </menu>
  </controls>
</node-details>

Node Details Buttons

The node details panel supports all the above-table buttons. In addition, it supports the following extra buttons:

  • <create-vm>
  • <destroy-all-vms>
  • <toggle-node-power>
  • <migrate-all-vms>
  • <remove-node>
  • <start-all-vms>
  • <stop-all-vms>

The <toggle-node-power> element, in addition to the standard button configuration, allows you to configure a custom button look for when the button can turn off a node, and another button look for when the button can turn a node on. This is done with the <on-button> and <off-button> child elements. An example is given below:

<toggle-node-power>
  <on-button image-url="images/power-green.png" tooltip="Power on server"/>
  <off-button image-url="images/power-red.png" tooltip="Power off server"/>
</toggle-node-power>

Sections

Each details panel section specified in XML corresponds to a collapsible section in the details panel. A section itself consists of a title (with no variable interpolation) and a <fields> element that contains a list of fields. These fields have names that correspond directly to the table fields described previously in the fields section.

In addition, the following fields are supported for both panels:

Note Several fields actually display a collection or list of scalar values. By default, these values are printed as a label of comma-separated values. However, if the field is given the attribute multiline="true", the field is displayed as a multi-select box with each individual collection value displayed on its own line. The fields that currently have this feature are labeled as collection fields.
  • <classes> - A collection.
  • <generic-events> - A table.
  • <generic-metrics> - A table.
  • <generic-resources> - A table.
  • <header> - This is used to add a line of header text meant to be a sub-header inside a details section or to separate groups of values in a details section.
  • <jobs> - A collection.
  • <os-options> - A collection.
  • <reservations> - A collection.
  • <resource managers> - A collection.
  • <variables> - A table.
  • <virtual-machines> - A collection.
  • <vm-os-options> A collection.

Linking

The Node Management Page can contain links to the VM Management Page. By including the <vm-count> tag in the node-management->table->fields->vm-count location a link to each Node's VMs makes it possible to navigate to the VM Management Page with the page filtered on the linking node. Note: The VM Management Page must contain the parent field.