Ad Widget

Collapse

Monitoring MSSQL tables

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • chewy
    Junior Member
    • Dec 2015
    • 9

    #1

    Monitoring MSSQL tables

    I've setup SQL monitoring with this template I found on the zabbix wiki
    Join the friendly and open Zabbix community on our forums and social media platforms.


    but I need to monitor the size of some tables and the only solution I can think of is to make a bunch of queries for every single value I want which seems very inefficient and adds load to the DB server for nothing.

    The following query gives me the size stats I want
    USE MYDB;
    GO
    EXEC sp_spaceused N'MYTABLE';
    GO

    but per the zabbix docs, the database monitor item can't use that query (and I'm no SQL expert and am having trouble finding an equivalent select statement).

    Assuming I can find a decent query, is there a way to take multiple data points from a query and map them to single values within zabbix?

    I don't have full control of the DB server so getting the windows agent on there is about all I can probably do and I don't know if I have any command line SQL stuff on there. It seems like maybe putting an sql file on the zabbix server and using unixodbc/zabbix sender might be a workaround but I don't really understand how to put the pieces togetes.

    Surely someone must have figured this out... care to share?
  • petar.tofevski
    Junior Member
    • Oct 2016
    • 4

    #2
    Still no answer?

    Did you succeed in setting up the monitoring of the tables?

    Comment

    Working...