Ad Widget

Collapse

How do I create useful memory triggers?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dennisj
    Junior Member
    • Apr 2010
    • 24

    #1

    How do I create useful memory triggers?

    I'm trying to create a trigger that is supposed to fire when a system runs out of memory but I'm not sure how to accomplish this. The default linux template contains such a trigger but that is not very useful because it doesn't take cache memory into account i.e. the free memory might reach zero and the trigger will fire even though there's 2G cache memory left.
    Is there a way to combine items in triggers and e.g. say "fire if (free + cache + buffer) < 10000"?
  • zabbix_zen
    Senior Member
    • Jul 2009
    • 426

    #2
    You can pretty much get any Trigger calculation you want.
    For that specific case,

    ({hostA:vm.memory.size[free].last(0)} + {hostA:vm.memory.size[cached] + {hostA:vm.memory.size[buffers])<10000


    Or you can do it at item level,
    search for 'Calculated Items' in the Manual

    Comment

    • harmonica
      Senior Member
      • Jan 2009
      • 251

      #3
      {hostA:vm.memory.size[available])<10000

      Comment

      • alixen
        Senior Member
        • Apr 2006
        • 474

        #4
        Hi,

        We have taken a different approach.
        We don't have any trigger based on free memory on Linux systems since they always try to use as much memory as possible.
        We have defined triggers on swap usage and we find them very useful.

        Regards,
        Alixen
        http://www.alixen.fr/zabbix.html

        Comment

        • dennisj
          Junior Member
          • Apr 2010
          • 24

          #5
          Originally posted by zabbix_zen
          You can pretty much get any Trigger calculation you want.
          For that specific case,

          ({hostA:vm.memory.size[free].last(0)} + {hostA:vm.memory.size[cached] + {hostA:vm.memory.size[buffers])<10000


          Or you can do it at item level,
          search for 'Calculated Items' in the Manual
          I successfully set up a calculated item. Thanks for the pointer!

          Comment

          • dennisj
            Junior Member
            • Apr 2010
            • 24

            #6
            Originally posted by jose_lourdes
            {hostA:vm.memory.size[available])<10000
            According to this page that key doesn't exist:
            http://www.zabbix.com/documentation/...ed_by_platform

            Comment

            • harmonica
              Senior Member
              • Jan 2009
              • 251

              #7
              Originally posted by dennisj
              According to this page that key doesn't exist:
              http://www.zabbix.com/documentation/...ed_by_platform
              The key is correct.
              Attached Files

              Comment

              • dennisj
                Junior Member
                • Apr 2010
                • 24

                #8
                Filed a bug against the documentation here:

                "The keys "vm.memory.size[pfree]" and "vm.memory.size[available]" are not documented"

                Comment

                Working...