Ad Widget

Collapse

File Size path too long

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Niven
    Junior Member
    • Apr 2005
    • 20

    #1

    File Size path too long

    Hi

    i'm trying to monitor a sql database file size but the location is too long as it is cut off.

    This is an example of the key: vfs.file.size[D:\Program Files\Microsoft SQL Server\MSSQL$Instancename\data\database.mdf]

    Its getting cut off at vfs.file.size[D:\Program Files\Microsoft SQL Server\MSSQL$\instances

    Is there a way round this?
  • Alexei
    Founder, CEO
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Sep 2004
    • 5654

    #2
    You may consider using aliases.
    Alexei Vladishev
    Creator of Zabbix, Product manager
    New York | Tokyo | Riga
    My Twitter

    Comment

    • drose12
      Junior Member
      • Apr 2007
      • 27

      #3
      can you elaborate? is this a windows shortcut or is an alias something you configure in zabbix?

      Comment

      • jroberson
        Senior Member
        • May 2008
        • 124

        #4
        Aliases are custom keys that you can define in your zabbix_agentd.conf file to return a custom value from a script or just to shorten and simplify the key that you need to use. For example:

        In zabbix_agentd.conf file on client server (agent):
        Code:
        Alias = mssql.db.size:vfs.file.size[D:\Program Files\Microsoft SQL Server\MSSQL$Instancename\data\database.mdf]
        Configure item in Zabbix Server -> Configuration -> Items and use this as the "key":
        Code:
        mssql.db.size
        That should get it working after you restart the "Zabbix Agent" service. You can find a few more examples in the forums or in the Zabbix manual.

        PS: The "mssql.db.size" is an arbitrary key name. You can call it anything you want.

        Comment

        Working...