Performance analytics via DBMS "plugins", or other solution

Posted by Polynomial on Server Fault See other posts from Server Fault or by Polynomial
Published on 2011-11-24T09:51:16Z Indexed on 2011/11/24 10:00 UTC
Read the original article Hit count: 1008

I'm working on a systems monitoring product that currently focuses on performance at the system level. We're expanding out to monitoring database systems. Right now we can fetch simple performance information from a selection of DBMS, like connection count, disk IO rates, lock wait times, etc.

However, we'd really like a way to measure the execution time of every query going into a DBMS, without requiring the client to implement monitoring in their application code.

Some potential solutions might be:

  • Some sort of proxy that sits between client and server. SSL might be an issue here, plus it requires us to reverse engineer and implement the network protocol for each DBMS.
  • Plugin for each DBMS system that automatically records performance information when a query comes in.

Other problems include "anonymising" the SQL, i.e. taking something like SELECT * FROM products WHERE price > 20 AND name LIKE "%disk%" and producing SELECT * FROM products WHERE price > ? AND name LIKE "%?%", though this shouldn't be too difficult with some clever parsing and regex.

We're mainly focusing on:

  • MySQL
  • MSSQL
  • Oracle
  • Redis
  • mongodb
  • memcached

Are there any plugin-style mechanisms we can utilise for any of these? Or is there a simpler solution?

© Server Fault or respective owner

Related posts about mysql

Related posts about sql-server