Forum Discussion

grilledcheez_21's avatar
grilledcheez_21
Icon for Nimbostratus rankNimbostratus
Sep 03, 2015

Monitor MySQL via Application

Hello,

 

We are attempting to setup monitors on our LTMs to monitor if the MySQL DB is active or not.

 

We have 4 Windows servers running an application, behind that application is our MySQL Databases. We thought we could use WMI to see if the services are up and active, but it seems the WMI monitors in the LTMs will only monitor the servers CPU/MEM/DISK Usage.

 

I found another article talking about using WMIC, but requires to be created on Linux Distro and then imported into the LTMs in order to monitor the services, but it seems overly complicated for the simple task of just wanting to monitor if the app and db are active.

 

Basically, we are just looking to setup two monitors, one for the app, which we can just use an existing TCP monitor for, and one for the DB. For the DB we need to make the call through the app and just have a small return string to match in order to say its active.

 

Can anyone help us out with this or point me in the right direction of what we're looking for? Even a small script?

 

Thanks.

 

5 Replies

  • Why not right a MySQL monitor that writes to a field on the DB. Only the active MySQL will allow writes as the other should be in read only mode correct?

     

    • grilledcheez_21's avatar
      grilledcheez_21
      Icon for Nimbostratus rankNimbostratus
      Will it work through the App though? The LTM is not directly attached to the DB and this system is heavily firewalled.
  • Greg_Crosby_319's avatar
    Greg_Crosby_319
    Historic F5 Account

    LTM module offers a MSSQL monitor option which may work for you. Using JDBC, the BIG-IP will make a specified query call to the pool of servers and only mark the member up if the specified receive string is returned by the database server.

     

    • grilledcheez_21's avatar
      grilledcheez_21
      Icon for Nimbostratus rankNimbostratus
      Will it work through the App though? The LTM is not directly attached to the DB and this system is heavily firewalled.
  • May not help much, but if the app is HTTP we normally offload this to the app, so we have a standard HTTP monitor hitting a specific resource on the app i.e. /status and get the app team to write something that queries the DB and returns a "SUCCESS" to the monitor if active.

     

    cheers