Version:

High Availability Configuration & Management

Pre-requisites

An HA installation requires two components:

  1. Two or more clusters with matching Kinetica installations registered with KAgent
  2. The KAgent UI

Configuration

  1. Log into the KAgent service with a web browser:

    http://<kagent-host>:8081
    
  2. On the Clusters page, click Enable Ring.

APIs

Any client API connection made to an HA cluster ring should be configured to fail over from one cluster to another.

Java

To instantiate a Kinetica connection object with failover in Java, pass a comma-delimited list of head node URLs to the constructor:

GPUdb gpudb = new GPUdb("http://172.1.2.3:9191,http://172.1.2.4:9191,http://172.1.2.5:9191");

In this case, a cluster will be chosen randomly from the given list for the initial connection. Subsequent requests through the instantiated connection object will go to the same cluster.

To designate a cluster from the list to always attempt to go to first, specify a primary URL:

GPUdb.Options options = new GPUdb.Options().setPrimaryUrl("http://172.1.2.4:9191");
GPUdb gpudb = new GPUdb("http://172.1.2.3:9191,http://172.1.2.4:9191,http://172.1.2.5:9191", options);

In either case, if the current cluster has a failure, the connector will randomly choose a failover cluster from the list to send further requests. If no operational clusters are found, an error will be returned.

Connectors

Any Kinetica connectors used to interface with an HA cluster ring should also be configured to fail over from one cluster to another.

ODBC

See Failover Connections for the ODBC/JDBC failover configuration.

Management

Once HA has been configured, several commands are available to aid in the management of the cluster. Run the following service with one of the commands from the table below:

service gpudb-ha <command>
Command Description
all-start Starts the gpudb, gpudb-ha, and gpudb-mq services.
all-status Displays the status of the gpudb, gpudb-ha, and gpudb-mq services.
all-stop Stops the gpudb, gpudb-ha, and gpudb-mq services.
backup-restart Restarts the backup processor service.
backup-start Starts the backup processor service.
backup-status Displays the status of the backup processor service.
backup-stop Stops the backup processor service.
gpudb-start Starts the gpudb and gpudb-ha services.
gpudb-status Displays the status of the gpudb and gpudb-ha services.
gpudb-stop Stops the gpudb and gpudb-ha services.
ha-restart Restarts the gpudb-ha service.
ha-start Starts the gpudb-ha service.
ha-status Displays the status of the gpudb-ha service.
ha-stop Stops the gpudb-ha service.
mq-restart Restarts the gpudb-mq service.
mq-status Displays the status of the gpudb-mq service.
mq-start Starts the gpudb-mq service.
mq-stop Stops the gpudb-mq service.
restart Restarts the gpudb-ha and backup processor services.
start Starts the gpudb-ha and backup processor services.
status Displays the status of the gpudb-ha and backup processor services.
stop Stops the gpudb-ha and backup processor services.