21.6.3 Event Reports Generated in NDB Cluster (original) (raw)
21.6.3 Event Reports Generated in NDB Cluster
In this section, we discuss the types of event logs provided by NDB Cluster, and the types of events that are logged.
NDB Cluster provides two types of event log:
- The cluster log, which includes events generated by all cluster nodes. The cluster log is the log recommended for most uses because it provides logging information for an entire cluster in a single location.
By default, the cluster log is saved to a file namedndb_ _`nodeid`__cluster.log
, (wherenodeid
is the node ID of the management server) in the management server'sDataDir.
Cluster logging information can also be sent tostdout
or asyslog
facility in addition to or instead of being saved to a file, as determined by the values set for theDataDir andLogDestination configuration parameters. SeeSection 21.4.3.5, “Defining an NDB Cluster Management Server”, for more information about these parameters. - Node logs are local to each node.
Output generated by node event logging is written to the filendb_ _`nodeid`__out.log
(wherenodeid
is the node's node ID) in the node'sDataDir. Node event logs are generated for both management nodes and data nodes.
Node logs are intended to be used only during application development, or for debugging application code.
Each reportable event can be distinguished according to three different criteria:
- Category: This can be any one of the following values:
STARTUP
,SHUTDOWN
,STATISTICS
,CHECKPOINT
,NODERESTART
,CONNECTION
,ERROR
, orINFO
. - Priority: This is represented by one of the numbers from 0 to 15 inclusive, where 0 indicates“most important” and 15 “least important.”
- Severity Level: This can be any one of the following values:
ALERT
,CRITICAL
,ERROR
,WARNING
,INFO
, orDEBUG
.
The cluster log can be filtered on these properties using the NDB management client CLUSTERLOG command. This command affects the cluster log only, and has no effect on the node logs; debug logging in one or more node logs can be turned on and off using the ndb_mgm NODELOG DEBUG command.
The format used in the cluster log is as shown here:
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 1: Data usage is 2%(60 32K pages of total 2560)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 1: Index usage is 1%(24 8K pages of total 2336)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 1: Resource 0 min: 0 max: 639 curr: 0
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 2: Data usage is 2%(76 32K pages of total 2560)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 2: Index usage is 1%(24 8K pages of total 2336)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 2: Resource 0 min: 0 max: 639 curr: 0
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 3: Data usage is 2%(58 32K pages of total 2560)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 3: Index usage is 1%(25 8K pages of total 2336)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 3: Resource 0 min: 0 max: 639 curr: 0
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 4: Data usage is 2%(74 32K pages of total 2560)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 4: Index usage is 1%(25 8K pages of total 2336)
2007-01-26 19:35:55 [MgmSrvr] INFO -- Node 4: Resource 0 min: 0 max: 639 curr: 0
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 4: Node 9 Connected
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 1: Node 9 Connected
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 1: Node 9: API 5.7.44-ndb-7.5.36
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 2: Node 9 Connected
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 2: Node 9: API 5.7.44-ndb-7.5.36
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 3: Node 9 Connected
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 3: Node 9: API 5.7.44-ndb-7.5.36
2007-01-26 19:39:42 [MgmSrvr] INFO -- Node 4: Node 9: API 5.7.44-ndb-7.5.36
2007-01-26 19:59:22 [MgmSrvr] ALERT -- Node 2: Node 7 Disconnected
2007-01-26 19:59:22 [MgmSrvr] ALERT -- Node 2: Node 7 Disconnected
Each line in the cluster log contains the following information:
- A timestamp in
_`YYYY`_-_`MM`_-_`DD`_ _`HH`_:_`MM`_:_`SS`_
format. - The type of node which is performing the logging. In the cluster log, this is always
[MgmSrvr]
. - The severity of the event.
- The ID of the node reporting the event.
- A description of the event. The most common types of events to appear in the log are connections and disconnections between different nodes in the cluster, and when checkpoints occur. In some cases, the description may contain status information.
For additional information, seeSection 21.6.3.2, “NDB Cluster Log Events”.