DB2 Version 9.7 for Linux, UNIX, and Windows

Capturing system metrics using the statistics event monitor

The statistics event monitor contains the metrics and the details_xml monitor elements in the event_scstats and event_wlstats logical data groups. Use these monitor elements to capture information about the system in XML documents. Alternatively, view the elements contained in the event_scmetrics and the event_wlmetrics groups.

The monitor elements metrics and details_xml are XML documents containing all the system monitor elements reported by the MON_GET_SERVICE_SUBCLASS_DETAILS and MON_GET_WORKLOAD_DETAILS table functions. System monitor elements are a subset of the details document reported in the DETAILS column of the MON_GET_SERVICE_SUBCLASS_DETAILS and MON_GET_WORKLOAD_DETAILS table functions.

Start of change If you create the event monitor such that the logical data groups event_scstats or event_wlstats are included in the event monitor output, metrics are reported in two XML documents contained in the event monitor output. The monitor elements reported in the metrics document show the change in value for the monitor elements since the last time statistics were collected. The elements reported in details_xml are the same monitor elements, however, they show the values since the database was activated. That is, they continue to increase until the database is deactivated. End of change

Important: Starting with Version 9.7 Fix Pack 6, the XML document details_xml is deprecated in the statistics event monitor, and might be removed in a future release. For more information, see Reporting of metrics in details_xml by the statistics event monitor has been deprecated.

Request monitor elements are controlled through the COLLECT REQUEST METRICS clause on service superclasses and the mon_req_metrics database configuration parameter at the database level. Monitor elements are only collected for a request if the request is processed by an agent in a service subclass whose parent service superclass has request monitor element collection enabled, or if request monitor element collection is enabled for the entire database. If request monitor element have been disabled at the database level, and for a service superclass, the metrics reported in the METRICS or DETAILS_XML documents stop increasing (or remain at 0 if request metrics were disabled at database activation time).

The schema for the XML document that is returned in the METRICS and DETAILS_XML columns is available in the file sqllib/misc/DB2MonCommon.xsd. The top level element is system_metrics.