getClusterPerf

Syntax

getClusterPerf([includeMaster=false])

Arguments

includeMaster (optional) indicates whether to include the controller information in the output.

Details

Returns configurations and performance measures for each node in the cluster. It can only be executed on the controller. It returns a table with the following columns:
Field Description Unit
host Host name
port Port number
site (LAN) site
mode Node type or deployment mode. 0: data node;1: agent; 2: controller; 3: standalone mode; 4: compute node.
state A Boolean value indicating whether the node is alive.
agentSite Agent information of the current node.
maxConnections The maximum number of connections (from GUI, API, other nodes, etc.) to the local node.
maxMemSize The maximum memory allocated to DolphinDB. GB
workerNum The size of worker pool for regular interactive jobs. The default value is the number of CPU cores
executorNum The number of local executors. The default value is the number of CPU cores - 1
connectionNum The number of connections to a local node. Note that the return value for the agent is a random number.
name Node alias
memoryUsed Memory used by the node Bytes
memoryAlloc Total memory allocated to DolphinDB on the node. Bytes
cpuUsage CPU usage
avgLoad Average CPU load
maxRunningQueryTime The maximum elapsed time of the queries that are currently running. ns
runningJobs The number of running jobs
queuedJobs The number of jobs in queue
runningTasks The number of running tasks
queuedTasks The number of tasks in queue
jobLoad CPU load of a job
diskCapacity Disk capacity Bytes
diskFreeSpace Available disk space Bytes
diskFreeSpaceRatio Available space ratio
diskWriteRate The rate at which data are written to disk. Bytes/sec
diskReadRate The rate at which data are read from disk. Bytes/sec
lastMinuteWriteVolume The data written to disk in the last minute. Bytes
lastMinuteReadVolume The data read from disk in the last minute. Bytes
networkSendRate The rate at which data are sent. Bytes/sec
networkRecvRate The rate at which data are received. Bytes/sec
lastMinuteNetworkSend Data sent in the last minute Byte
lastMinuteNetworkRecv Data received in the last minute Byte
publicName Returns publicName for a controller configured with publicName;Otherwise returns the MAC (Media Access Control) Address of the server for a controller, data node or agent.
lastMsgLatency Latency of the last received message ns
cumMsgLatency Cumulative latency of the messages ns
isLeader Whether it is the leader of a raft group. It only returns for a raft group of controllers. Note that it will return NULL for a raft group with crashed node.
The following measures are displayed only when the configuration parameter perfMonitoring is set to 1.
Field Description Unit
medLast10QueryTime The median execution time of the previous 10 finished queries. ns
maxLast10QueryTime The maximum execution time of the previous 10 finished queries. ns
medLast100QueryTime The median execution time of the previous 100 finished queries. ns
maxLast100QueryTime The maximum execution time of the previous 100 finished queries. ns

Examples

rpc(getControllerAlias(), getClusterPerf,true)
host port site mode state agentSite maxConnections maxMemSize workerNum executorNum connectionNum name memoryUsed memoryAlloc cpuUsage avgLoad medLast10QueryTime maxLast10QueryTime medLast100QueryTime maxLast100QueryTime maxRunningQueryTime runningJobs queuedJobs runningTasks queuedTasks jobLoad diskCapacity diskFreeSpace diskFreeSpaceRatio diskWriteRate diskReadRate lastMinuteWriteVolume lastMinuteReadVolume networkSendRate networkRecvRate lastMinuteNetworkSend lastMinuteNetworkRecv publicName lastMsgLatency cumMsgLatency
192.168.1.48 8,894 192.168.1.48:8894:datanode3 0 1 192.168.1.48:8891:agent1 192 16 16 15 4 datanode3 9,073,704 12,648,448 1.0309 0.0103 0 0 0 0 0 0 0 0 0 0 1,000,068,870,144 941,631,864,832 0.9416 0 0 1,058 0 0 0 0 0 0 127.0.0.1 0 0
192.168.1.48 8,895 192.168.1.48:8895:datanode4 0 1 192.168.1.48:8891:agent1 192 16 16 15 4 datanode4 8,862,912 9,502,720 0 0 0 0 0 0 0 0 0 0 0 0 1,000,068,870,144 941,631,864,832 0.9416 0 0 1,058 0 0 0 0 0 0 127.0.0.1 0 0
192.168.1.48 8,891 192.168.1.48:8891:agent1 1 1 192.168.1.48:8891:agent1 32 12 4 15 0 agent1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
192.168.1.48 8,892 192.168.1.48:8892:datanode1 0 1 192.168.1.48:8891:agent1 192 16 16 15 4 datanode1 8,976,200 10,551,296 0 0 0 0 0 0 0 0 0 0 0 0 1,000,068,870,144 941,631,864,832 0.9416 0 0 1,058 0 0 0 0 0 0 127.0.0.1 0 0
192.168.1.48 8,893 192.168.1.48:8893:datanode2 0 1 192.168.1.48:8891:agent1 192 16 16 15 5 datanode2 9,290,232 11,599,872 0 0 0 0 0 0 0 0 0 0 0 0 1,000,068,870,144 941,631,864,832 0.9416 0 0 1,058 0 0 0 0 0 0 127.0.0.1 0 0
rpc(getControllerAlias(), getClusterPerf).keys()
["host","port","site","mode","state","agentSite","maxConnections","maxMemSize","workerNum","executorNum","connectionNum","name","memoryUsed","memoryAlloc","cpuUsage","avgLoad","medLast10QueryTime","maxLast10QueryTime","medLast100QueryTime","maxLast100QueryTime","maxRunningQueryTime","runningJobs","queuedJobs","runningTasks","queuedTasks","jobLoad","diskCapacity","diskFreeSpace","diskFreeSpaceRatio","diskWriteRate","diskReadRate","lastMinuteWriteVolume","lastMinuteReadVolume","networkSendRate","networkRecvRate","lastMinuteNetworkSend","lastMinuteNetworkRecv","publicName","lastMsgLatency","cumMsgLatency"]

For a high-availability cluster:

rpc(getControllerAlias(), getClusterPerf)
host port site mode state agentSite maxConnections maxMemSize workerNum executorNum connectionNum name memoryUsed memoryAlloc cpuUsage avgLoad medLast10QueryTime maxLast10QueryTime medLast100QueryTime maxLast100QueryTime maxRunningQueryTime runningJobs queuedJobs runningTasks queuedTasks jobLoad diskCapacity diskFreeSpace diskFreeSpaceRatio diskWriteRate diskReadRate lastMinuteWriteVolume lastMinuteReadVolume networkSendRate networkRecvRate lastMinuteNetworkSend lastMinuteNetworkRecv publicName lastMsgLatency cumMsgLatency isLeader
192.168.100.10 17,000 192.168.100.10:17000:master3 2 1 512 16 64 3 1 master3 23,449,272 24,133,632 0.7788 0.0037 0 0 0 0 0 0 0 0 0 0 0 0 0 0 4,658 2,736 102,468 59,193 78,351 8,012,182 2,378,846 192.198.1.10;172.17.0.1;10.244.5.0;10.244.5.1 0 0 false
192.168.100.11 17,000 192.168.100.11:17000:master2 2 1 512 16 64 3 2 master2 23,527,872 24,133,632 11.5625 0.3219 0 0 0 0 0 0 0 0 0 0 0 0 0 0 4,670 2,785 116,733 62,402 56,160 1,366,293 1,398,238 192.198.1.11;172.17.0.1;10.244.4.0;10.244.4.1 0 0 false
192.168.100.12 17,000 192.168.100.12:17000:master1 2 1 512 16 64 3 20 master1 25,002,792 46,538,752 14.0406 0.1136 0 0 0 0 0 0 0 0 0 0 0 0 0 0 4,671 13,546,528 19,964,606 53,206 56,891 22,543,771 8,226,278 192.198.1.12;172.17.0.1;10.244.3.0;10.244.3.1 0 0 true
192.168.100.12 17,102 192.168.100.12:17102:server19-datanode1 0 1 192.168.100.12:17101:server19-agent1 254 120 5 31 1 server19-datanode1 23,118,960 24,133,632 13.928 0.1136 0 0 0 0 0 0 0 0 0 0 17,790,585,659,392 16,826,060,464,128 0.9458 0 4,687 1,289 23,477 44,197 55,104 352,258 6,163,159 192.198.1.12;172.17.0.1;10.244.3.0;10.244.3.1 0 0
192.168.100.11 17,102 192.168.100.11:17102:server18-datanode1 0 1 192.168.100.11:17101:server18-agent1 254 120 5 31 1 server18-datanode1 23,111,912 24,133,632 14.1066 0.3219 0 0 0 0 0 0 0 0 0 0 17,790,585,659,392 16,714,392,956,928 0.9395 0 4,698 1,989 23,530 40,896 50,706 243,008 250,727 192.198.1.11;172.17.0.1;10.244.4.0;10.244.4.1 0 0
192.168.100.11 17,101 192.168.100.11:17101:server18-agent1 1 1 192.168.100.11:17101:server18-agent1 304 4 4 63 0 server18-agent1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 192.198.1.11;172.17.0.1;10.244.4.0;10.244.4.1 0 0
192.168.100.10 17,102 192.168.100.10:17102:server17-datanode1 0 1 192.168.100.10:17101:server17-agent1 254 120 5 31 1 server17-datanode1 40,872,496 52,445,184 0.7788 0.0037 0 0 0 0 0 0 0 0 0 0 53,783,736,754,176 50,336,934,432,768 0.9359 0 4,699 13,900,218 18,835 118,935 109,862 6,170,512 408,018 192.198.1.10;172.17.0.1;10.244.5.0;10.244.5.1 0 0
192.168.100.12 17,101 192.168.100.12:17101:server19-agent1 1 1 192.168.100.12:17101:server19-agent1 304 4 4 63 0 server19-agent1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 192.198.1.12;172.17.0.1;10.244.3.0;10.244.3.1 0 0
192.168.100.10 17,101 192.168.100.10:17101:server17-agent1 1 1 192.168.100.10:17101:server17-agent1 304 4 4 63 0 server17-agent1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 192.198.1.10;172.17.0.1;10.244.5.0;10.244.5.1 0 0