C H A P T E R 9 |
This chapter describes the Cluster Membership Manager (CMM) statistics that can be accessed from the NMA.
The CMM statistics collected by the NMA provide the role and status of each node in the cluster.
When a direct link is configured between the master-eligible nodes, the NMA can monitor the following statistics:
For information about the direct link, see the Netra High Availability Suite 3.0 1/08 Foundation Services Overview.
Because it is possible to set a timeout value for CMM operations, it is also possible that CMM operations cannot be completed during the time allowed. If the timeout value is too short, some or all CMM operations will fail. For more information about this CMM behavior, see the cmm_connect3CMM man page.
The CmmMasterStatisticsMBean MBean interface makes master state information available. One MBean implementing the CmmMasterStatisticsMBean interface is instantiated on the CMM cluster master node.
To get the average time in seconds between nodes when starting the CMM, invoke the getAverageElectionDelay method. This information can be used for tuning the master election mechanism. The getAverageElectionDelay method takes no parameters, and returns an int.
To get the number of CMM clients currently connected, invoke the getClientCount method. The getClientCount method takes no parameters, and returns an int. This information is available on all nodes.
To get the lifetime of the CMM on this node, expressed in the number of seconds since boot, invoke the getCmmUpTime method. The getCmmUpTime method takes no parameters, and returns an int. This information is available on all nodes.
To get the number of elections processed on the platform, invoke the getElectionCount method. The getElectionCount method takes no parameters, and returns an int.
To get the maximum time in seconds between nodes when starting the CMM, invoke the getMaxElectionDelay method. The getMaxElectionDelay method takes no parameters, and returns an int. This information can be used for tuning the election mechanism.
To get the minimum time in seconds between nodes when starting the CMM, invoke the getMinElectionDelay method. The getMinElectionDelay method takes no parameters, and returns an int. This information can be used for tuning the election mechanism.
To get the number of nodes acknowledged by the master node as being present in the cluster, invoke the getPresentNodeCount method. The getPresentNodeCount method takes no parameters, and returns an int.
To get the number of requests currently outstanding, invoke the getRequestCount method. The getRequestCount method takes no parameters, and returns an int. This information is available on all nodes.
The ClusterNodeMBean MBean interface exposes the CMM view of the local node on which the agent runs. This MBean interface makes the CMM state information of the current node available. One MBean implementing the ClusterNodeMBean interface is instantiated in each management agent in the cluster. The MBean that implements this interface is the emitter of the java.com.sun.nhas.ma.cmm.NhasCmmNotification.
To return the CGTP address of a node, invoke the getCgtpAddress method. The getCgtpAddress method takes no parameters, and returns a String. This is not a symbolic name for the node. Having the IP address in dot-notation makes it possible to avoid translation into IP format.
To return the domain ID of the cluster that a node is eligible to join, invoke the getDomainId method. The getDomainId method takes no parameters, and returns an int. The domain ID identifies the cluster that the node can join. A cluster is composed of nodes that have the same domain ID. Two nodes running incompatible versions of a software package must have different domain IDs. Nodes can only belong to one cluster. The ID of that cluster is the domain ID of the current node as defined in the CMM configuration. Because the CMM is only aware of what occurs in its own cluster, the domain ID field will be the same for all nodes reachable from this node. This information is useful when interpreting CMM debug traces, which will refer to this domain ID when necessary.
To return the incarnation number, invoke the getIncarnationNumber method. The incarnation number is computed locally by each node. The value of the incarnation number is the time of the last reboot expressed in the number of seconds since epoch (01/01/1970). The getIncarnationNumber method takes no parameters, and returns a long.
To get the membership role of this node, invoke the getMembershipRole method. This information is extracted from the CmmStateFlag. The getMembershipRole method takes no parameters, and returns a com.sun.nhas.ma.cmm.CmmMembershipRoleEnum, which is one of the following values:
MASTER | The node is the current cluster master node. |
VICEMASTER | The node is the current vice-master node. |
IN_CLUSTER | The node is a regular node in the cluster. |
OUT_OF_CLUSTER | The node is down. |
To return the unique ID that identifies this node within the cluster, invoke the getNodeId method. This information is useful when interpreting CMM debug traces, which refer to this ID. The getNodeId method takes no parameters, and returns an int.
To get a human-readable String that uniquely identifies this node within the cluster, invoke the getNodeName method. The name is not intended to be a parameter to be passed to system calls. It is intended to be used to format display messages. For instance, this name could be formatted to refer to the position of the card on a shelf to make it easy for an operator to locate and replace it in case of failure. The getNodeName method takes no parameters, and returns a String.
To return the ID of the current boot image used by this node, invoke the getSoftwareLoadId method. Since CMM is only aware of the domain ID, if two nodes run two incompatible boot images they must have different domain IDs and different software load IDs. The getSoftwareLoadId method takes no parameters, and returns a String.
To return the membership state flags of a node, invoke the getStateFlags method. These flags are a concatenation of the administrative attributes, the membership roles, and the qualification as seen from the perspective of the CMM. The getStateFlags method takes no parameters, and returns a CmmStateFlag.
The CmmStatisticsMBean MBean provides statistics about the service performed by the CMM. Some of these statistics will only be available on the master node. Others will be available on each node in the cluster. One MBean instance is instantiated for each NMA on the cluster.
To get the average time in seconds between nodes when starting the CMM, invoke the getAverageElectionDelay method. The getAverageElectionDelay method takes no parameters, and returns an int. This information can be used for tuning the election mechanism. This information is available on the master node only.
To get the number of elections processed on the platform, invoke the getElectionCount method. The getElectionCount method takes no parameters, and returns an int. This information is available on the master node only.
To get the maximum time in seconds between nodes when starting the CMM, invoke the getMaxElectionDelay method. The getMaxElectionDelay method takes no parameters, and returns an int. This information can be used for tuning the election mechanism. This information is available on the master node only.
To get the minimum time in seconds between nodes when starting the CMM, invoke the getMinElectionDelay method. The getMinElectionDelay method takes no parameters, and returns an int. This information can be used for tuning the election mechanism. This information is available on the master node only.
To get the number of nodes acknowledged by the master node as being present in the cluster, invoke the getPresentNodeCount method. The getPresentNodeCount method takes no parameters, and returns an int. This information is available on the master node only.
To get the number of switchovers performed, invoke the getSwitchOverCount method. The getSwitchOverCount method takes no parameters, and returns an int. This information is available on the master node only.
To get the number of CMM clients currently connected, invoke the getClientCount method. The getClientCount method takes no parameters, and returns an int. This information is available on all nodes.
To get the number of requests currently outstanding, invoke the getRequestCount method. The getRequestCount method takes no parameters, and returns an int. This information is available on all nodes.
Copyright © 2008, Sun Microsystems, Inc. All rights reserved.