in reply to Mysql Health script

You probably want to use SHOW STATUS instead of SHOW VARIABLES.

And add use strict and use warnings to your script - this will pay off.

Replies are listed 'Best First'.
Re^2: Mysql Health script
by aalneyperl (Acolyte) on Nov 16, 2007 at 14:01 UTC
    i want to use show variables,show status and show slave status once and fetch there values periodically whenever i need them for calculation.

      There is some simple Perl code in the book "High Performance Mysql" which does a slave check. Very good book by the way.

      Have you considered to use nagios (or other monitoring solutions)? There are some plugins for nagios that deal with Mysql.

        hi, thanks stark..it did help, however i still am stuck with picking up the variables dynamically and using it for calculation..