The CSO feature is to utilize information available in Information_Schema (as well as Performance_Schema of MySQL 5.5+) that are not exposed in the basic SHOW statements we have been using in the monitors/advisors. In addition to the Performance_Schema SELECT queries any query which returns a result set can be monitored.

CSOs not only lets you monitor server metrics but also lets you monitor server data.

A CSC is based on any user-defined SQL query returning a result set. The array returned by MySQL from the SQL query populates a SQL DM for MySQL Object (a ”Custom SQL Object” (CSO) in this case). This is exposed as a javascript array that may be referenced in SQL DM for MySQL counter definitions like any SQL DM for MySQL object.

Enabling pre-defined CSCs and CSOs:

In order to monitor CSOs you need to create a Custom SQL Counter(CSC). SQL DM for MySQL comes shipped with a bunch of pre-defined CSCs with their respective CSOs. By default, all pre-defined CSOs and CSCs are disabled. To enable some of these samples follow these steps:

  1. Click the drop-down icon beside the title Monitors -> Manage CSO. The twenty-eight pre-defined CSOs display in the left menu.
    As an example select the DiskInfo item. The User Defined SQL-query displays in the SQL box. Sample interval and retention timeframe specific for this CSO may be changed as per your preference and you may specify for which MySQL server(s) this particular CSO should be collected. Also note that one or more Key columns are defined. It must be a column or a set of columns returning (a) unique (set of) value(s) (similar to a UNIQUE KEY in MySQL). Without defining a Key Column, the result monitors might now show proper values.
  2. Go to Monitors page, select Manage Monitor Groups, enable the DiskInfo Group, and Save the changes. This pre-defined group contains pre-defined CSC’s using the CSOs you enabled in the previous step.
  3. Go to Monitors page, select the DiskInfo group that now displays at the bottom. You can see five new counters in that group that in various ways reference the CSOs that we just enabled (click the counter name and next ‘Customize’ as usually to see the javascript code). Customize those further as you want to do with any counter in SQL DM for MySQL.

SQL Diagnostic Manager for MySQL agentless and cost-effective performance monitoring for MySQL and MariaDB.
IDERAProductsPurchase | Support | Community | Resources | About Us | Legal
  • No labels