Product Documentation

Configuring a NetScaler Cluster

Apr 10, 2015

You can use NITRO to add or create and manage a NetScaler cluster.

Cluster Instance Operations

All operations on a cluster instance must be performed on the clusterinstance object.

For example, to create a cluster instance with ID 1, connect to the NetScaler appliance that you are first adding to the cluster:

  • Request:

    HTTP Method
    POST
    URL
    http://<netscaler-ip-address>/nitro/v1/config/clusterinstance
    Request Headers
    Cookie:NITRO_AUTH_TOKEN=<tokenvalue> 
    Content-Type:application/json
    
    Request Payload
    { 
        "clusterinstance": 
        { 
            "clid":1, 
            "preemption":"ENABLED" 
        } 
    } 
    
  • Response:

    HTTP Status Code on Success
    201 Created
    HTTP Status Code on Failure
    4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error.

Cluster Node Operations

All operations on a cluster node must be performed on the clusternode object.

For example, to add a NetScaler appliance with NSIP address 10.102.29.60 to the cluster:
  • Request:

    HTTP Method
    POST
    URL
    http://<netscaler-ip-address>/nitro/v1/config/clusternode
    Request Headers
    Cookie:NITRO_AUTH_TOKEN=<tokenvalue> 
    Content-Type:application/json
    
    Request Payload
    { 
        "clusternode": 
        { 
            "nodeid":1, 
            "ipaddress":"10.102.29.60", 
            "state":"ACTIVE", 
            "backplane":"1/1/2" 
        } 
    }
    
  • Response:

    HTTP Status Code on Success
    201 Created
    HTTP Status Code on Failure
    4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error.

Add a Cluster IP Address

To define a cluster IP address, specify the required parameters in the nsip object.

For example, to configure a cluster IP address:

  • Request:

    HTTP Method
    POST
    URL
    http://<netscaler-ip-address>/nitro/v1/config/nsip
    Request Headers
    Cookie:NITRO_AUTH_TOKEN=<tokenvalue> 
    Content-Type:application/json
    
    Request Payload
    { 
        "nsip": 
        { 
            "ipaddress":"10.102.29.61",  
            "netmask":"255.255.255.255", 
            "type":"CLIP" 
        } 
    }
    
  • Response:

    HTTP Status Code on Success
    201 Created
    HTTP Status Code on Failure
    4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error.

Add a Spotted IP Address

To configure an IP address as spotted, specify the required parameters in the nsip object. This configuration must be done on the cluster IP address.

For example, to configure a spotted SNIP address on a node with ID 1:

  • Request:

    HTTP Method
    POST
    URL
    http://<cluster-ip-address>/nitro/v1/config/nsip
    Request Headers
    Cookie:NITRO_AUTH_TOKEN=<tokenvalue> 
    Content-Type:application/json
    
    Request Payload
    { 
        "nsip": 
        { 
            "ipaddress":"10.102.29.77",  
            "netmask":"255.255.255.0", 
            "type":"SNIP", 
            "ownernode":1 
        } 
    }
    
  • Response:

    HTTP Status Code on Success
    201 Created
    HTTP Status Code on Failure
    4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error.

Join NetScaler Appliance to Cluster

To join an appliance to a cluster, specify the required parameters in the cluster object.

For example, to join a NetScaler appliance to a cluster:

  • Request:

    HTTP Method
    POST
    URL
    http://<netscaler-ip-address>/nitro/v1/config/cluster
    Request Headers
    Cookie:NITRO_AUTH_TOKEN=<tokenvalue> 
    Content-Type:application/json
    
    Request Payload
    { 
        "cluster": 
        { 
            "clip":"10.102.29.61", 
            "password":"verysecret" 
        } 
    }
    
  • Response:

    HTTP Status Code on Success
    200 OK
    HTTP Status Code on Failure
    4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error.

Linkset Operations

To configure a linkset, do the following:

  1. Create a linkset by specifying the required parameters in the linkset object.
    For example, to add a linkset LS/1:
    • Request:

      HTTP Method
      POST
      URL
      http://<cluster-ip-address>/nitro/v1/config/linkset
      Request Headers
      Cookie:NITRO_AUTH_TOKEN=<tokenvalue> 
      Content-Type:application/json
      
      Request Payload
      { 
          "linkset": 
          { 
              "id":"LS/1" 
          } 
      }
      
    • Response:

      HTTP Status Code on Success
      201 Created
      HTTP Status Code on Failure
      4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error.
  2. Bind the required interfaces to the linkset by specifying the interfaces in the linkset_interface_binding object.
    For example, to bind interfaces 1/1/2 and 2/1/2 to linkset LS/1:
    • Request:

      HTTP Method
      PUT
      URL
      http://<cluster-ip-address>/nitro/v1/config/linkset_interface_binding/LS%2F1?action=bind
      Note: The linkset name (LS/1), must be URL encoded as LS%2F1.
      Request Headers
      Cookie:NITRO_AUTH_TOKEN=<tokenvalue> 
      Content-Type:application/json
      
      Request Payload
      { 
          "linkset_interface_binding": 
          { 
              "id":"LS/1", 
              "ifnum":"1/1/2 2/1/2" 
          } 
      }
      
    • Response:

      HTTP Status Code on Success
      200 OK
      HTTP Status Code on Failure
      4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error.