Nodes/network: POST

Gets information on all networks that are configured and are operational for a group of nodes.

Availability

Available on all IBM Storage Scale editions.

Description

The POST nodes/network request gets information on the networks that are configured and are operational on a group of nodes. You can send parameters like target nodes, cluster name, log files, and other attributes in the request body to view the relevant node details. For more information about the fields in the data structures that are returned, see mmnetverify command.

Request URL

https://<IP address or host name of API server>:<port>/scalemgmt/v2/nodes/network
where
network
Specifies the resource for which you need to get the details. Required.

Request headers

Accept: application/json

Request parameters

The following parameters can be used in the request URL to customize the request:
Table 1. List of request parameters
Parameter name Description and applicable keywords Required/optional
body Body of the request that contains the required parameters to be passed on to the IBM Storage Scale system to perform the requested operation. Optional.

Request data

The following attributes are available in the request data.
{
  "operation": "port|all|data|local|bandwidth",
  "node": "Node name",
  "targetNodes": "Target node names",
  "clusterName": "Cluster IP address",
  "configFile": "File path",
  "pingPacket": Size,
  "logFile": "File path",
  "addr": "subnet list",
  "verbose": true | false,
  "cesOverride": "CES-enabled ",
  "minBandwidth": Bandwidth size,
  "maxThreads": Number of threads
}
The details of the attributes are given in the following list.
"operation": "port|all|data|local|bandwidth"
The operations that are run against the target nodes to check network configuration and operation. You can specify more than one operation. Each operation is separated by a blank.
"node": "Node name"
The list of nodes on which to run the command. If you specify more than one node, the command is run on all the specified nodes in parallel. Each node tests all the specified target nodes. If you do not specify any value for this parameter, the command runs the operations only from the node where you enter the command.
"targetNodes": "Targetnode name"
The list of nodes that are the targets of the testing. If you do not specify this parameter, the command runs the operations against all the nodes in the cluster.
"targetNodes": "Targetnode name"
The list of nodes that are the targets for the testing. If you do not specify this parameter, the command runs the operations against all the nodes in the cluster.
"clusterName": "Cluster IP address"
The name of a remote cluster followed by at least one contact node identifier.
"configFile": "file path"
The path of a configuration file.
"pingPacket": "Size"
The size, in bytes, of the ICMP echo request packets that are sent between the local node and the target node during the ping test. The size must not be greater than the MTU of the network interface. If the MTU size of the network interface changes, for example to support jumbo frames, you can specify this parameter to verify that all the nodes in the cluster can handle the new MTU size.
"logFile": "File path"
The path of a file where the output messages from the network checks are stored. If you do not specify this parameter, messages are displayed only on the console.
"addr": "Subnet list"
The list of subnets that the command searches in a sequential order for a subnet that both the local node and the target node are connected to.
"verbose": true | false
Specifies whether verbose output messages are generated.
"cesOverride": "CES-enabled"
Specifies whether the nodes in the configuration are CES-enabled. This parameter overrides the requirement of the protocol-ctdb and the protocol-object network checks that the local node and the target nodes must be CES-enabled with the mmchnode command. This parameter is automatically set if a value is specified for the configFile parameter.
"minBandwidth": size
The minimum acceptable bandwidth for the data bandwidth check.
"maxThreads": size
The number of nodes that can run the command in parallel. The valid range is 1 - 64 and the default value is 32. For more information, see the mmnetverify command.

Response data

The following attributes are available in the response data:


{      
"status": {
      "code":ReturnCode",
      "message":"ReturnMessage"
   },
   "mmnetverify": [
    {
      "localNode": "Node name",
      "targetNode": "Target node name",
      "test": "Test nodes",
      "data": "Data size",
      "status": "Network status"
    }
  ]
}    
The details of the parameters are given in the following list:
"status":
Return status.
"message": "ReturnMessage",
The return message.
"code": ReturnCode
The return code.
"mmnetverify"
The command that is run.
"localNode": "Node name"
The node from which a network test is run.
"targetNode": "Target node name"
The node against which a test is run.
"test": "Test nodes"
The nodes that are involved in the test, including both local nodes and target nodes.
"data": "Data size"
The size of data messages specified for network checks.
"status": "Network status"
The network status.

Examples

The following example gets information on the network configuration and operation.

Request URL:
curl -X POST --header 'Content-Type: application/json' --header 'Accept: text/html' --header 'Authorization: Basic YWRtaW46YWRtaW4wMDE=' -d '{ \ 
   "operation": "all", \ 
   "node": "node1-11", \ 
   "targetNodes": "node1-12", \ 
   "clusterName": "9.114.204.107", \ 
   "configFile": "string", \ 
   "pingPacket": 0, \ 
   "logFile": "string", \ 
   "addr": "string", \ 
   "verbose": false, \ 
   "cesOverride": "string", \ 
   "minBandwidth": 0, \ 
   "maxThreads": 0 \ 
 }' 'https://198.51.100.1:443/scalemgmt/v2/nodes/network'
Response data:
Note: In the JSON data that is returned, the return code indicates whether the command is successful. The response code 200 indicates that the command successfully retrieved the information. Error code 400 represents an invalid request and 500 represents internal server error.
{
  "status": {
    "code": "200",
    "message": "..."
  },
  {
    "mmnetverify": [
        {
            "data": "0",
            "localNode": "node1-11",
            "status": "0",
            "targetNode": "",
            "test": "interface"
        },
        {
            "data": "node1-11",
            "localNode": "node1-11",
            "status": "0",
            "targetNode": "node1-11",
            "test": "resolution"
        },
        {
            "data": "node1-11",
            "localNode": "node1-11",
            "status": "0",
            "targetNode": "node1-11",
            "test": "ping"
        },
        {
            "data": "node1-11",
            "localNode": "node1-11",
            "status": "0",
            "targetNode": "node1-11",
            "test": "shell"
        },
        {
            "data": "node1-11",
            "localNode": "node1-11",
            "status": "0",
            "targetNode": "node1-11",
            "test": "copy"
        }
        ]
        }
}