Ad Widget

Collapse

Exclude Monitored Filesystem.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • iwidjaya
    Junior Member
    • Apr 2016
    • 16

    #1

    Exclude Monitored Filesystem.

    I have a requirement to monitor filesystem but only certain type of filesystem, exclude those NFS, proc, etc2.

    I'm trying to set this up in Regular expression, create a customFSType and then put the string out there:

    ^(nfs|cachefs|nfs3|nfsv3|cdfs|hsfs|iso9660|cdrfs|p roc|usbdevfs|devpts|procfs|mvfs|nfsd|sysfs|nfs4|un known)$

    Result is FALSE

    Then, in the template, I create a discovery rule, inside Filter tab, i added macro like {#FSTYPE} matches @CustomFSType.

    Still I don't get what I want as it is seems to show all filesystem mount.

    How to troubleshoot this what go wrong, can anyone help?
  • kloczek
    Senior Member
    • Jun 2006
    • 1771

    #2
    You have typos in proc. In your regexp is "p roc" and "un known".

    In m filtering I'm using longer regexp

    Code:
    ^(autofs|binfmt_misc|cgroup|cifs|configfs|debugfs|devpts|devtmpfs|fusectl|gvfsd-fuse|hugetlbfs|is|mqueue|nfs|none|proc|pstore|rootfs|rpc_pipefs|securityfs|selinux|sysfs|systemd-1|tmpfs|usbfs)$
    and probably even that is not all
    Last edited by kloczek; 02-08-2016, 07:27.
    http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
    https://kloczek.wordpress.com/
    zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
    My zabbix templates https://github.com/kloczek/zabbix-templates

    Comment

    • iwidjaya
      Junior Member
      • Apr 2016
      • 16

      #3
      override trigger, possible?

      i apply the filter and looking good now, thanks.

      now i need to know how possible we can override the triggers.

      i create trigger prototypes for all Filesystem (generic) with 2 threshold, let's say >= 85 and <90, another one >= 90.

      trigger 1:
      {template1:vfs.fs.size[{#FSNAME},pused].last()}>=85 and {template1 Default FileSystem:vfs.fs.size[{#FSNAME},pused].last()}<90

      trigger 2:
      {template1:vfs.fs.size[{#FSNAME},pused].last()}>=90

      and then on top of that, i create a specific one for a particular filesystem, let's say /boot with only 1 threshold: >= 95.

      trigger 3:
      {template1:vfs.fs.size[{#FSNAME},pused].last()}>={$CRITICAL_THRESHOLD2:"{#FSNAME}"}

      am using macro where i can switch:
      {$CRITICAL_THRESHOLD2:/boot} => 95.

      when /boot reaching 100%, it triggers both trigger 2 and trigger 3, though i only expect 1 which is trigger 3.

      is this possible? if yes, how we can achieve this scenario where we only want to generate 1 instead of 2?

      Comment

      Working...