LoadMaster Clustering (Beta)

1Introduction

Clustering involves deployment of multiple LoadMaster instances (nodes) as a single management and control domain where each node is actively passing traffic. If any of these nodes fail - the remaining nodes continue to provide service to the remote client, providing resilience.

Clustering supports scaling - LoadMaster nodes can be added to or removed from a cluster so that capacity can be dynamically adjusted to match business requirements. Each additional LoadMaster node which is added to the cluster can provide a linear increase in throughput and performance. The maximum number of nodes that can be added to a cluster is defined by your license agreement.

An example use case is - if a website experiences higher than usual traffic during a holiday period and the amount of traffic cannot be predicted in advance - often the capacity is over-provisioned to handle these requests that come in spikes. One of the simplest solutions is to deploy LoadMasters in a cluster and then add new nodes as the capacity requirements (concurrent connections and performance requirements) increase.

1.1Document Purpose

The purpose of this document is to provide information on the LoadMaster clustering feature and step-by-step instructions on how to set up and configure clustering.

1.2Intended Audience

This document is intended to be read by anyone who is interested in finding out more about LoadMaster clustering.

2LoadMaster Clustering

2.1Prerequisites

There are some prerequisites to be aware of before clustering LoadMasters:

  • Technically, a minimum of two LoadMasters are needed to set up clustering. However, there are no scaling or resiliency benefits until there are at least three LoadMasters.
  • Ideally, all of the LoadMasters in the cluster should be identical in terms of the hardware used. Clustering also works with Virtual LoadMasters but the Virtual Machines must have the same resources, for example CPU, memory and Hard Disk Drive (HDD), assigned.
  • The LoadMasters being added to the cluster should be factory default - i.e. mostly using default settings (apart from the IP configuration settings). When clustering is configured, most configuration changes are performed using the Web User Interface (WUI) of the shared IP address. The configuration is then propagated to all nodes in the cluster.

2.2Restrictions

Most functionality that is available in a single LoadMaster is available when a LoadMaster environment is clustered. The only restrictions (which are in place due to the way clustering is implemented) are listed below:

  • All Virtual Services must operate at Layer 7. No Layer 4 Virtual Services can be used.
  • Transparency cannot be enabled
  • Subnet originating addresses are always enabled
  • High Availability (HA) mode cannot be used
  • VXLAN and IPsec tunneling are not supported

2.3Clustering Overview

Figure 2‑1: LoadMaster clustering - example architecture

With LoadMaster clustering, the load-balancing capability can be extended as needed by adding additional LoadMasters for the same Virtual Service. Traffic which is intended for a failed node is either passed on to an existing node or load-balanced across the remaining nodes.

The LoadMasters all work in parallel. If a LoadMaster node fails, traffic is redistributed amongst the remaining nodes. Health checking is performed on each of the LoadMasters.

Most administrative changes should be made on the shared IP address interface. These changes then get propagated to the LoadMasters in less than a second. Local administration of the individual LoadMasters can also be performed by accessing the WUI of the units directly. The WUI of the local LoadMasters contain limited configuration options.

2.4Configuring Clustering

If clustering is enabled on the LoadMaster, the Cluster Control menu item will be available under System Configuration in the main menu of the LoadMaster WUI. If clustering functionality is not enabled and you would like to use it, please contact your KEMP representative.

2.4.1Create a New Cluster and Add Nodes to it

To set up a cluster and add LoadMaster nodes to it, follow the steps in the sections below, in order.

2.4.1.1Create a New Cluster

To create a new cluster, follow the steps below on a LoadMaster WUI:

  1. In the main menu of the LoadMaster WUI, go to System Configuration > Cluster Control.

Figure 2‑2: Convert to Cluster

  1. Click Create New Cluster.

Figure 2‑3: Creating a New Cluster

  1. Enter the desired shared IP address for the cluster.

This is the address that will be used to access the shared WUI where configuration changes should be made.

  1. Click Set Shared Address.
  2. Click Create a Cluster.

Figure 2‑4: Rebooting

  1. The LoadMaster will then reboot. A prompt will appear asking to reconnect to the shared IP address.
  1. Click Continue.

When the LoadMaster is finished rebooting, you will be brought to the shared IP address.

The cluster is now set up. The next step is to add a LoadMaster to the cluster.

2.4.1.2Add a Node LoadMaster to the Cluster

To add a node LoadMaster to the cluster, the node LoadMaster needs to become available and then have its IP address added in the shared IP address WUI. To do this, follow the steps below:

  1. In the node WUI, go to System Configuration > Cluster Control in the main menu.

Figure 2‑5: Add to Cluster

  1. Click Add to Cluster.

Figure 2‑6: Waiting to Join Cluster

The LoadMaster is now available to be added to the cluster.

  1. Open the WUI of the shared IP address.
  2. In the main menu, go to System Configuration > Cluster Control.

Figure 2‑7: Add New Node

  1. Enter the IP address of the node LoadMaster in the Address text box.
  2. Click Add New Node.

This must be done while the node LoadMaster is available to join the cluster.

Figure 2‑8: Reboot

  1. The LoadMaster needs to reboot to finish the conversion to cluster mode. Click Continue.

Figure 2‑9: Enable node

  1. By default, the new node will be disabled. Click Enable to enable the node in the cluster.

When a node is enabled, it will not be immediately be brought into rotation. It will only come online after it has been up for 30 seconds. The page may need to be refreshed to display any state changes.

  1. Click OK.

The cluster is now configured and a node has been added. To add more nodes, repeat the steps in Section 2.4.1.2.

When all nodes have been added to the cluster, other configuration changes can be made - such as creating and configuring Virtual Services. These changes will be propagated from the shared IP address to the LoadMaster nodes.

2.4.1.3Configure the Network Interface(s)

Some configuration changes are needed on the interfaces. Refer to the sections below for further details.

2.4.1.3.1Set the Cluster Shared IP Address

The cluster shared IP address needs to be set on any interfaces that will be used to handle traffic. To do this, follow the steps below:

  1. In the main menu of the shared IP address LoadMaster WUI, go to System Configuration > Network Setup.
  1. Click the relevant interface link.

Figure 2‑10: Network Interface Management

  1. Enter the Cluster Shared IP address and click Set Shared address.
2.4.1.3.2Enable the Use for Cluster Checks Option

The Use for Cluster checks option must be enabled on at least one interface. To enable this option, follow the steps below:

  1. In the main menu of the LoadMaster WUI, expand System Configuration.
  1. Click the relevant interface.

Figure 2‑11: Network Interface Management

  1. Tick the Use for Cluster Checks check box.
2.4.1.3.3Enable the Use for Default Gateway Option

The Use for Default Gateway option needs to be enabled on each of the LoadMasters.

To do this, follow the steps below:

  1. In the main menu of a node LoadMaster, expand System Configuration.
  2. Click the relevant interface.

Figure 2‑12: Network Interface Management

  1. Tick the Use for Default Gateway check box.

2.4.2Remove a Node LoadMaster from the Cluster

It is possible to remove a node LoadMaster from the cluster which will mark the node as unavailable for new traffic (i.e. a Draining state) to facilitate the removal from the cluster. To do this, follow the steps below in the shared IP address WUI:

  1. In the main menu, go to System Configuration > Cluster Control.

Figure 2‑13: Cluster Control

  1. Click Disable on the node to be removed.

Before a node can be deleted, it must first be disabled. The node must also be online. A node cannot be deleted if it is handling traffic.

Figure 2‑14: Draining

  1. The node will change to a Draining state. Wait for the node to finish draining and change to a Disabled state.

The page will need to be refreshed to see the new state.

When a node is in the Draining state, the connections that are still being served by the node are allowed to continue for the amount of time specified in the Node Drain Time text box. For more information, refer to Section 2.6.2.1. No new connections will be handled by the node during this time.

  1. Click Delete to remove the node from the cluster.
  2. Click OK to confirm the removal.
  3. Click OK to the confirmation message.

When a node is deleted it becomes a regular single LoadMaster instance. If the LoadMaster is later added back in to the cluster, any configuration changes that have been made in the shared IP address will propagate to the node LoadMaster.

2.4.3Changing the Cluster Parameters

The cluster Virtual ID and node drain time can be updated, if needed. Refer to the sections below for further information.

2.4.3.1Updating the Cluster Virtual ID

When using multiple clusters or LoadMaster HA systems on the same network, the virtual ID identifies each cluster so that there are no potential unwanted interactions. To change the cluster ID, follow the steps below in the shared IP address WUI:

  1. In the main menu, go to System Configuration > Cluster Control.

Table 2‑1: Show Options

  1. Click the Show Options button.

Table 2‑2: Cluster Virtual ID

  1. Change the Cluster Virtual ID value.

Valid values range from 1 to 255.

  1. Click Set Cluster Virtual ID.
2.4.3.2Updating the Node Drain Time

When a node is disabled, the connections that are still being served by the node are allowed to continue for the amount of seconds specified in the Node Drain Time text box. No new connections will be handled by the node during this time. The Node Drain Time is set to 10 seconds by default. To change the Node Drain Time, follow the steps below in the shared IP address WUI:

  1. In the main menu, go to System Configuration > Cluster Control.

Table 2‑3: Show Options

  1. Click the Show Options button.

Table 2‑4: Set Node Drain Time

  1. Change the value in the Node Drain Time text box.

Valid values range between 1 and 600 (seconds).

  1. Click Set Node Drain Time.

2.4.4Backing Up and Restoring the Configuration

Backups can be taken and restored as usual in the System Configuration > System Administration > Backup/Restore section of the LoadMaster WUI. Backups and restores should only be performed on the shared IP address because the changes made there will be propagated to the other nodes. When restoring, the individual LoadMasters get rebooted, one at a time.

There are certain settings that need to be set in the Virtual Services for them to work with clustering:

  • Transparency must be disabled
  • Subnet Originating Requests must be enabled
  • All Virtual Services must operate at Layer 7. No Layer 4 Virtual Services can be used.
  • High Availability (HA) mode cannot be used

As a result of these restrictions, there may be issues with restoring a backup taken from a non-cluster LoadMaster on to a cluster LoadMaster and vice versa, because the settings may be incompatible.

2.5Cluster-Wide Software Updates

The firmware on all LoadMasters in a cluster can be updated via the shared IP address.

Software updates require the LoadMasters to be rebooted. However, the nodes can be rebooted one by one so there is no down time.

To perform a cluster-wide software update, follow the steps below in the WUI of the shared IP address:

  1. Get a LoadMaster firmware patch file.

Visit support.kemptechnologies.com or Contact KEMP Support to get a LoadMaster firmware patch.

  1. In the main menu, go to System Configuration > Update Software.

Table 2‑5: Update Cluster

  1. Click Choose File.
  2. Browse to and select the firmware update patch file.
  3. Click Update Cluster.
  4. Click OK to continue.

Table 2‑6: Validating software update

  1. Wait for the software update to be transferred and validated.

Table 2‑7: Software Update Validated

  1. Click OK to install the software update.

Table 2‑8: New software installed

  1. A message will appear saying that the new software has been installed and the Cluster Control screen will be displayed.
  2. Each of the non-admin nodes need to be rebootedin order to activate the software. Click Reboot to reboot a node.
  3. Click OK to the pop-up message.

Table 2‑9: Reboot the admin node

  1. When all non-admin nodes have been rebooted, the admin node needs to be rebooted. Click Reboot in the admin node row to reboot the admin node.

2.6Clustering WUI Options

2.6.1General WUI Options

Figure 2‑15: Cluster Control

If clustering functionality is enabled on a non-node LoadMaster, a Cluster Control menu option should be available in the WUI within the System Configuration section.

Figure 2‑16: Convert to Cluster

Before setting up clustering, clicking the Cluster Control menu item will give the option to either create a new cluster or add this LoadMaster to a cluster.

Figure 2‑17: Local IP menu Figure 2‑18: Shared IP menu

When logging in to the cluster, use the shared IP address to view and set the full functionality of the cluster nodes. Logging in to the local IP address of any of the nodes displays different menu options (see menus above). Logging in to one of the nodes directly is usually reserved for maintenance.

2.6.2Cluster Control WUI Options

Figure 2‑19: Cluster Options

Create New Cluster: If setting up a new cluster, click this button.

Add to Cluster: Add this LoadMaster to an already existing LoadMaster.

Figure 2‑20: Creating a New Cluster

When the Create New Cluster button is clicked, the screen above will appear which prompts to set the shared IP address of the cluster. The shared IP address is the address which will be used to administer the cluster.

Figure 2‑21: Rebooting

When the Create a Cluster button is clicked, the LoadMaster reboots. A message will appear asking to reconnect to the shared IP address that was just set.

Figure 2‑22: Cluster Control

After creating a cluster, the Cluster Control screen in the WUI of the shared IP address will allow the addition of LoadMaster nodes into the cluster.

A LoadMaster can only be added to a cluster when the cluster is available and waiting to join the cluster. Refer to Section 2.4.1.2for further information and steps.

Figure 2‑23: Cluster Control

The Cluster Control screen, in the shared IP address WUI, displays details for each of the nodes in the cluster.

Show Options: Clicking the Show Options button will display the Cluster Parameters section which contains two additional fields which can be used to set the Cluster Virtual ID and Node Drain Time. For further information, refer to Section 2.6.2.1.

ID: The cluster ID.

Address: The IP address of the LoadMaster node. If a second IP address appears in brackets after the first one - the second IP address is the IP address of the interface port. The IP address and status text will be coloured depending on the status:

  • Blue: The node is the master node.
  • Yellow: The node is disabled.
  • Green: The node is up.
  • Red: The node is down.

Status: The status of the node. The possible statuses are:

  • Admin: The node is the primary control node.
  • Up: The node is up.
  • Down: The node is down.
  • Drain stopping: The node has been disabled and the connections arebeing shut down in an orderly fashion. Drain stopping lasts for 10 seconds by default. This can be updated by changing the Node Drain Time value on the Cluster Control screen. For more information, refer to Section 2.4.3.2.
  • Disabled: The node is disabled - connections will not be sent to that node.

Operation: The different operations that can be performed in relation to the notes:

  • Add new node: Add a new node with the specified IP address to the cluster.
  • Disable: Disable the node. Nodes that are disabled will first go through drain stopping. During the drain stopping time, the connections are shut down in an orderly fashion. After the drain, the node will be disabled and no traffic will be directed to that node.
  • Enable: Enable the node. When a node comes up, it will not be immediately be brought into rotation. It will only come online after it has been up for 30 seconds.
  • Delete: Delete a node from the cluster. When a node is deleted it becomes a regular single LoadMaster instance. If the LoadMaster is later added back in to the cluster, any configuration changes that have been made in the shared IP address will propagate to the node LoadMaster.
2.6.2.1Cluster Parameters

Figure 2‑24: Cluster Parameters

When the Show Options button is clicked, the Cluster Parameters section appears. This section contains two additional WUI options - Cluster Virtual ID and Node Drain Time.

Cluster Virtual ID

When using multiple clusters or LoadMaster HA systems on the same network, the virtual ID identifies each cluster so that there are no potential unwanted interactions. The cluster virtual ID is set to 1 by default, but it can be changed if required. Valid IDs range from 1 to 255. Changes made to an admin Loadmaster propagate across all nodes in the cluster.

 

 

 

 

Node Drain Time

When a node is disabled, the connections that are still being served by the node are allowed to continue for the amount of seconds specified in the Node Drain Time text box. No new connections will be handled by the node during this time. The Node Drain Time is set to 10 seconds by default, but it can be changed if required. Valid values range from 1 to 600 (seconds).

During the drain time the status changes to Draining until the specified drain time elapses.

When the drain time has elapsed the status changes to disabled.

2.6.3Cluster Interface Options

There are a couple of fields relating to clustering in the Network Interface management screen.

Figure 2‑25: Network Interface Management

To get to this screen, go to System Configuration > Network Setup in the main menu of the LoadMaster WUI and click one of the interfaces. The cluster-related options are described below.

Cluster Shared IP address

Specify the shared IP address which can be used to access the cluster. This is also used as the default source address when using Server NAT.

Use for Cluster checks

Use this option to enable cluster health checking between the admin Loadmaster and the nodes. At least one interface must be enabled.

2.6.4Cluster-Wide Software Update WUI Options

Table 2‑10: Update Cluster

The firmware on all LoadMasters in a cluster can be updated via the shared IP address.

This can be done in System Configuration > System Administration > Update Software by using the Update Cluster option.

Figure 2‑26: Reboot

After the firmware update patch has been uploaded, a new Reboot button will appear on the Cluster Control screen.

For more information, including step-by-step instructions on how to perform a cluster-wide software update, refer to Section 2.5.Application Program Interface (API) Commands

KEMP supports three APIs that can be used to allow remote applications to access the LoadMaster in a simple and consistent manner:

  • RESTful API
  • PowerShell API
  • Java API

2.7API Clustering Commands

Clustering can be configured using API commands. For details on each of the commands that can be used, refer to the relevant section below.

2.7.1RESTful API Clustering Commands

The sections below provide details on each of the RESTful API commands relating to clustering. For step-by-step instructions on how to configure clustering via the RESTful API, refer to Section 2.7.2.

2.7.1.1Get the Status of the Cluster

To retrieve the status of the cluster, run the command below:

https://<LoadMasterIPAddress>/access/cluster/status

The data for all nodes in the cluster is returned. It lists all the enabled nodes in the cluster in XML format.

If the LoadMaster is not in a cluster an error message will be returned via the WUI.

2.7.1.2Create a Cluster

If a LoadMaster is not in currently in cluster mode, it can be converted to cluster mode by running the command below:

https://<LoadMasterIPAddress>/access/cluster/create?SharedAddress=<SharedIPAddress>

2.7.1.3Initiate a Node Joining a Cluster

To initiate a node joining a cluster, run the following command on the LoadMaster:

https://<LoadMasterIPAddress>/access/cluster/joincluster

Running this command will make the LoadMaster available to be added to the cluster. To finish adding the node, please run the addnode command. Refer to Section 2.7.1.4for further information.

2.7.1.4Add a Node to the Cluster

Before running this command, the node LoadMaster needs to be available to be added. To make the node LoadMaster available, run the joincluster command on the node LoadMaster. Refer to Section 2.7.1.3 for further information on the joincluster command.

If the addnode command is run when the node LoadMaster is not available to be added, an error will be returned which says that the machine could not be contacted.

To add a node to the cluster (while the node LoadMaster is available to be added), run the following command on the shared IP address:

https://<LoadMasterIPAddress>/access/cluster/addnode?Address=<NodeIPAddress>

2.7.1.5Enable a Node

When a node is first added to the cluster it is disabled by default. To enable a node, run the following command:

https://<LoadMasterIPAddress>/access/cluster/enablenode?nodeid=<NodeID>

The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI, or by running the status command (Section 2.7.1.1).

2.7.1.6Disable a Node

To disable a node, run the following command:

https://<LoadMasterIPAddress>/access/cluster/disablenode?nodeid=<NodeID>

The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI, or by running the status command (Section 2.7.1.1).

2.7.1.7Delete a Node

To delete a node from a cluster, run the command below:

https://<LoadMasterIPAddress>/access/cluster/deletenode?NodeId=<NodeID>

The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI, or by running the status command (Section 2.7.1.1).

2.7.2RESTful API Clustering Example

The sections above provide details relating to each of the clustering RESTful API commands. This section provides step-by-step instructions on how to create a cluster and add a node to it. The example IP addresses which are used in the example commands are below:

  • LoadMaster 1: 10.154.11.10
  • LoadMaster 2: 10.154.11.20
  • Shared IP Address: 10.154.11.30
  • Node ID: 2

Follow the steps below in sequential order to create a cluster and add a node to it:

  1. Create a cluster. Run this command on LoadMaster 1:

https://10.154.11.10/access/cluster/create?SharedAddress=10.154.11.30

  1. Initiate the node (LoadMaster 2) joining a cluster.Run this command on LoadMaster 2:

https://10.154.11.20/access/cluster/joincluster

  1. Add the node (LoadMaster 2) to the cluster. Run this command on LoadMaster 1:

https://10.154.11.10/access/cluster/addnode?Address=10.154.11.20

The addnode command must be run while the node LoadMaster is available to join the cluster. This command should be run immediately after the joincluster command.

If the addnode command is run when the node LoadMaster is not available to be added, an error will be returned which says that the machine could not be contacted.

  1. Enable the node. Run this command on LoadMaster 1:

https://10.154.11.10/access/cluster/enablenode?nodeid=2

2.7.3PowerShell API Clustering Commands

The sections below provide details on each of the PowerShell API commands relating to clustering. For step-by-step instructions on how to configure clustering via the PowerShell API, refer to Section 2.7.4.

In the examples below, it is assumed that the Initialize-LoadBalancer command has been run on the relevant LoadMaster. If the command has not been run, the Address and Credential parameters must be included in each individual command. For further information, please refer to the PowerShell, Interface Description.NMClusterStatus

To retrieve the status of the cluster, run the NMClusterStatus command.

Example Command

NMClusterStatus

 

 

 

 

Available Parameters

Parameter

Parameter Type

Parameter Description

Mandatory

LoadBalancer

String

The shared IP address of the cluster.

No

Credential

Object

Specifies a user account that has permission to administer the load balancer. You can either enter a username for the load balancer or provide a PSCredential object, such as an object that is returned by the Get-Credential cmdlet. When you type a username, you are prompted for a password.

No

Figure 2‑27: NMClusterStatus parameters

Expected Output

Node SharedAddress

---- -------------

1,172.20.0.135,172.21.99.101,1,5,2,172.20.0.136,172.21.99.102,1,1,3,172.... 172.20.0.140

2.7.3.1NMClusterCreate

If a LoadMaster is not in cluster mode, it can be converted to cluster mode by running the NMClusterCreate command.

Example Command

NMClusterCreate -SharedAddress 10.11.0.31

Available Parameters

Parameter

Parameter Type

Parameter Description

Mandatory

SharedAddress

String

The initial shared IP address of the cluster.

Yes

LoadBalancer

String

The IP address of the KEMP device that you are directing the command to. This can be set globally by using the Initialize-LoadBalancer command, but can be overridden on each individual command by using this parameter.

No

Credential

Object

Specifies a user account that has permission to administer the load balancer. You can either enter a username for the load balancer or provide a PSCredential object, such as an object that is returned by the Get-Credential cmdlet. When you type a username, you are prompted for a password.

No

Expected Output

ok

2.7.3.2NMJoinCluster

To initiate a node joining a cluster, run the NMJoinCluster command on the node LoadMaster.

This makes the node LoadMaster available to be added. To finish adding the node, please run the NMAddNode command on the shared IP address. For more information, refer to Section 2.7.5.4.

Example Command

NMJoinCluster

Available Parameters

Parameter

Parameter Type

Parameter Description

Mandatory

LoadBalancer

String

The shared IP address of the cluster.

No

Credential

Object

Specifies a user account that has permission to administer the load balancer. You can either enter a username for the load balancer or provide a PSCredential object, such as an object that is returned by the Get-Credential cmdlet. When you type a username, you are prompted for a password.

No

Table 2‑11: NMJoinCluster parameters

Expected Output

ok

2.7.3.3NMAddNode

Run the NMAddNode command to add a single node LoadMaster (which is available to be added) to the cluster.

Before running this command, the node LoadMaster needs to be be available to be added. To make the node LoadMaster available, run the NMJoinCluster command. For more information, refer to Section 2.7.3.2. If the NMAddNode command is run when the node LoadMaster is not available, an error will be returned which says that the machine could not be contacted.

Example Command

NMAddNode -Address 10.154.11.20

 

 

Available Parameters

Parameter

Parameter Type

Parameter Description

Mandatory

Address

String

The IP address of the node LoadMaster.

Yes

LoadBalancer

String

The IP address of the KEMP device that you are directing the command to. This can be set globally by using the Initialize-LoadBalancer command, but can be overridden on each individual command by using this parameter.

No

Credential

Object

Specifies a user account that has permission to administer the load balancer. You can either enter a username for the load balancer or provide a PSCredential object, such as an object that is returned by the Get-Credential cmdlet. When you type a username, you are prompted for a password.

No

Table 2‑12: NMAddNode parameters

Expected Output

ok

2.7.3.4NMEnableNode

To enable a node, run the NMEnableNode command.

Example Command

NMEnableNode -NodeId 2

Available Parameters

Parameter

Parameter Type

Parameter Description

Mandatory

NodeId

Int32

The ID number of the node to be enabled. The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI.

Yes

LoadBalancer

String

The IP address of the KEMP device that you are directing the command to. This can be set globally by using the Initialize-LoadBalancer command, but can be overridden on each individual command by using this parameter.

No

Credential

Object

Specifies a user account that has permission to administer the load balancer. You can either enter a username for the load balancer or provide a PSCredential object, such as an object that is returned by the Get-Credential cmdlet. When you type a username, you are prompted for a password.

No

Table 2‑13: NMEnableNode parameters

Expected Output

ok

2.7.3.5NMDisableNode

To disable a node, run the NMDisableNode command.

Example Command

NMDisableNode -NodeId 2

Available Parameters

Parameter

Parameter Type

Parameter Description

Mandatory

NodeId

Int32

The ID number of the node to be disabled. The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI.

Yes

LoadBalancer

String

The IP address of the KEMP device that you are directing the command to. This can be set globally by using the Initialize-LoadBalancer command, but can be overridden on each individual command by using this parameter.

No

Credential

Object

Specifies a user account that has permission to administer the load balancer. You can either enter a username for the load balancer or provide a PSCredential object, such as an object that is returned by the Get-Credential cmdlet. When you type a username, you are prompted for a password.

No

Table 2‑14: NMDisableNode parameters

Expected Output

ok

2.7.3.6NMDeleteNode

To delete a node from a cluster, run the NMDeleteNode command.

Example Command

NMDeleteNode -NodeId 2

Available Parameters

Parameter

Parameter Type

Parameter Description

Mandatory

NodeId

Int32

The ID number of the node to be deleted. The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI.

Yes

LoadBalancer

String

The IP address of the KEMP device that you are directing the command to. This can be set globally by using the Initialize-LoadBalancer command, but can be overridden on each individual command by using this parameter.

No

Credential

Object

Specifies a user account that has permission to administer the load balancer. You can either enter a username for the load balancer or provide a PSCredential object, such as an object that is returned by the Get-Credential cmdlet. When you type a username, you are prompted for a password.

No

Table 2‑15: NMDeleteNode parameters

Expected Output

ok

2.7.4PowerShell API Clustering Example

The sections above provide details relating to each of the clustering PowerShell API commands. This section provides step-by-step instructions on how to create a cluster and add a node to it. The example IP addresses which are used in the example commands are below:

  • LoadMaster 1: 10.154.11.10
  • LoadMaster 2: 10.154.11.20
  • Shared IP Address: 10.154.11.30
  • Node ID: 2

In the example below, it is assumed that the Initialize-LoadBalancer command has been run on both LoadMaster 1 and LoadMaster 2. If the command has not been run, the Address and Credential parameters must be included in each individual command. For further information, please refer to the PowerShell, Interface Description.

Follow the steps below in sequential order to create a cluster and add a node to it:

  1. Create a cluster (on LoadMaster 1):

NMClusterCreate -SharedAddress 10.154.11.30

  1. Initiate the node (LoadMaster 2) joining a cluster:

NMJoinCluster

  1. Add the node (LoadMaster 2) to the cluster (on LoadMaster 1):

NMAddNode -Address 10.154.11.20

The NMAddNode command must be run while the node LoadMaster is available to join the cluster. This command should be run immediately after the NMJoinCluster command.

If the LMAddNode command is run when the node LoadMaster is not available to be added, an error will be returned which says that the machine could not be contacted.

  1. Enable the node (on LoadMaster 1):

NMEnableNode -NodeId 2

2.7.5Java API Clustering Commands

2.7.5.1nmClusterStatus

public LoadMasterResponse nmClusterStatus()

throws Utils.InvalidApiParametersException

Retrieve the status of the cluster.

Returns: A LoadMasterResponse object containing the parsed response from the LoadMaster Parsed XML LoadMasterResponse object

Throws: Utils.InvalidApiParametersException - Exception when an invalid parameter/value is used.

2.7.5.2nmClusterCreate

publicLoadMasterResponsenmClusterCreate(java.lang.StringSharedAddress)

throws Utils.InvalidApiParametersException

If a LoadMaster is not in cluster mode, it can be converted to cluster mode by running this command.

Parameters:

SharedAddress - The initial shared IP address of the cluster.

 

 

Returns:

A LoadMasterResponse object containing the parsed response from the LoadMaster Parsed XML LoadMasterResponse object

Throws:

Utils.InvalidApiParametersException - Exception when an invalid parameter/value is used.

2.7.5.3nmJoinCluster

public LoadMasterResponse nmJoinCluster()

throws Utils.InvalidApiParametersException

To initiate a node joining a cluster, run this command on the node LoadMaster.

This makes the node LoadMaster available to be added to the cluster. To finish adding the node, please run thenmAddNode command. Refer to Section 2.7.5.4for further information.

Returns: A LoadMasterResponse object containing the parsed response from the LoadMaster Parsed XML LoadMasterResponse object

Throws: Utils.InvalidApiParametersException - Exception when an invalid parameter/value is used.

2.7.5.4nmAddNode

public LoadMasterResponse nmAddNode(java.lang.String Address)

throws Utils.InvalidApiParametersException

Before running this command, the node LoadMaster needs to be available to be added. To make the node available to be added, run the nmJoinCluster command on the node LoadMaster. Refer to Section 2.7.5.3 for further information on the joincluster command.

If the nmAddNode command is run when the node LoadMaster is not available to be added, an error will be returned which says that the machine could not be contacted.

To add a node to the cluster (while the node LoadMaster is available to be added), run this command on the shared IP address.

Parameters:

Address - The IP address of the node LoadMaster.

Returns: A LoadMasterResponse object containing the parsed response from the LoadMaster Parsed XML LoadMasterResponse object

Throws: Utils.InvalidApiParametersException - Exception when an invalid parameter/value is used.

2.7.5.5nmEnableNode

public LoadMasterResponse nmEnableNode(java.lang.String NodeId)

throws Utils.InvalidApiParametersException

When a node is first added to the cluster it is disabled by default. To enable a node, run the this command.

Parameters:

NodeId - The ID number of the node to be enabled. The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI, or by running the nmClusterStatus command (Section 2.7.5.1).

Returns: A LoadMasterResponse object containing the parsed response from the LoadMaster Parsed XML LoadMasterResponse object

Throws: Utils.InvalidApiParametersException - Exception when an invalid parameter/value is used.

2.7.5.6nmDisableNode

public LoadMasterResponse nmDisableNode(java.lang.String NodeId)

throws Utils.InvalidApiParametersException

Disable a node.

Parameters:

NodeId - The ID number of the node to be disabled. The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI, or by running the nmClusterStatus command (Section 2.7.5.1).

Returns: A LoadMasterResponse object containing the parsed response from the LoadMaster Parsed XML LoadMasterResponse object

Throws: Utils.InvalidApiParametersException - Exception when an invalid parameter/value is used.

2.7.5.7nmDeleteNode

public LoadMasterResponse nmDeleteNode(java.lang.String NodeId)

throws Utils.InvalidApiParametersException

Delete a node from a cluster.

Parameters:

NodeId - The ID number of the node to be deleted. The ID of the node can be found in the ID column in the Cluster Control screen in the LoadMaster WUI, or by running the nmClusterStatus command (Section 2.7.5.1).

Returns: A LoadMasterResponse object containing the parsed response from the LoadMaster Parsed XML LoadMasterResponse object

Throws: Utils.InvalidApiParametersException - Exception when an invalid parameter/value is used.

2.8Troubleshooting

Logs are recorded to track certain clustering events, such as when a node goes offline. Viewing the logs can help to troubleshoot problems which may occur. To view the logs relating to clustering, in the LoadMaster WUI go to System Configuration > Logging Options > System Log Files. The logs relating to clustering are available in the Warning Message File and the System Message File.

Some examples of log entries relating to clustering are listed and described below.

The following log example shows a node failing and a partner node becoming the main admin node.

lb100 ucarp[2994]: [WARNING]

Switching to state: MASTER

lb100 ucarp[21751]: [CRITICAL]

Partner has failed, becoming

MASTER

ucarp[2995]: [WARNING]

Switching to state: MASTER

ucarp[2995]: [WARNING]

Preferred master advertised:

going back to BACKUP state

ucarp[2995]: [CRITICAL] Partner

has failed, becoming MASTER

lb100 l4d: HA state changed:

now master.

The following log example shows a node going offline. This could be because the node was rebooted.

lb100 l4d: Node 3 now dead

lb100 l4d: Cluster running on

only 3 of 4 nodes

The following log example indicates that a node has gone offline.

lb100 l4d: Cluster running on 3

of 4 nodes (1 disabled)The following log example indicates that a node is alive, for example a disabled node has been enabled.

lb100 l4d: Node 3 now alive

References

Unless otherwise specified, the following documents can be found at http://www.kemptechnologies.com/documentation.

PowerShell, Interface Description High Availability (HA), Feature Description

Document History

Date

Change

Reason for Change

Version

Resp.

Apr 2015

Initial draft

First draft of document

1.0

LB

June 2015

Changes to reflect beta

Beta version changes

1.1

LB

Aug 2015

New sections added

API steps added

3.0

LB

Sep 2015

Release updates

Updates for 7.1-30

4.0

LB

Was this article helpful?

0 out of 0 found this helpful

Comments