vCloud Director can collect metrics that provide current and historic information about virtual machine performance and resource consumption for the virtual machines that are in your cloud. Data for historic metrics is stored in a KairosDB database backed by a Cassandra cluster.

Cassandra and KairosDB are open source databases that, when deployed together, provide a scalable, high-performance solution for collecting time series data like virtual machine metrics. If you want your cloud to support retrieval of historic metrics from virtual machines, you must install and configure Cassandra and KairosDB, then use the cell-management-tool utility to connect vCloud Director to KairosDB. Retrieval of current metrics does not require optional database software.

To support retrieval of historic metrics, vCloud Director requires a Cassandra cluster. A Cassandra cluster consists of one or more machines on which you have installed Cassandra and are running the Cassandra service. For a typical vCloud Director installation, you should have at least three machines in the Cassandra cluster. Because the vCloud Director metrics monitoring feature uses a replication factor of two, having three machines, the nodes, in the Cassandra cluster ensures that a node is always available to handle a transaction. You can use a single Cassandra cluster for your vCloud Director installation.

You also need at least one instance of KairosDB configured to work with your Cassandra cluster. If your cloud collects historic metrics from many virtual machines, additional instances of KairosDB might be needed. You can either install and configure KairosDB on one of the Cassandra nodes and point the cell management tool to that endpoint, or install and configure KairosDB on each Cassandra node, add a load balancer in front of the configuration, and point the cell management tool at the load balancer endpoint. Because vCloud Director expects to communicate with KairosDB at a single IP address, installations that include multiple instances of KairosDB must use a load balancer to provide that address and distribute vCloud Director requests to the KairosDB instances.

Verify that vCloud Director is installed and running before you configure the optional database software.

If you are not already familiar with Cassandra and KairosDB, review the material available at http://cassandra.apache.org/ and https://code.google.com/p/kairosdb/.

Obtain either Cassandra 1.2.x or Cassandra 2.0.x from http://cassandra.apache.org/download/.

Obtain KairosDB 0.9.1 from https://code.google.com/p/kairosdb/.

Complete the installation and configuration of the Cassandra cluster that you plan to use with your vCloud Director installation, according to this configuration:

Cassandra 1.2.x or Cassandra 2.0.x is installed on at least three machines that are connected to the same network that your vCloud Director cells use.

The machines are configured to have their own physical storage, and not shared storage.

The machines are configured as a Cassandra cluster.

Java Native Access (JNA) version 3.2.7 or later is enabled for the Cassandra cluster, to improve performance of memory usage and disk access.

Complete the installation and configuration of at least one instance of KairosDB 0.9.1 on one of the Cassandra nodes, to use your Cassandra cluster as its database. You can also install and configure KairosDB on each Cassandra node if you add a load balancer in front of that configuration.

Verify that KairosDB and Cassandra are configured correctly. Use a Web browser to browse to http://KairosDB-IP:8080/api/v1/metricnames. If the page opens without an error, KairosDB and Cassandra are configured correctly.

Verify that you can run the service command of the cell-management-tool utility. For details about the service command, see Start or Stop vCloud Director Services.

1

Use the cell-management-tool utility to configure a connection between vCloud Director and KairosDB.

Use a command like this, where KairosDB-IP is the IP address of the machine on which you installed KairosDB, or the IP address of the load balancer you are using to distribute requests to multiple instances of KairosDB.

[root@cell1 /opt/vmware/vcloud-director/bin]# ./cell-management-tool configure-metrics 
  --repository-host KairosDB-IP --repository-port 8080
2

Restart each vCloud Director cell using the service command of the cell-management-tool utility.