Ad Widget

Collapse

Alarm won´t be closed

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • SQ_AM
    Junior Member
    • Jul 2025
    • 3

    #1

    Alarm won´t be closed


    We have a template that monitors folders and if there are files in the Error folder, an alarm is generated. When a file is deleted from the Error folder, the alarm is automatically closed. The same template is used in all our hosts. Now in one host, an alarm is generated from one Error folder, but it does not close even though the file has been deleted from that Error folder. All other alarms from other Error folders close normally. I removed the host from Zabbix and added it again. When the alarm from that same Error folder came again, the same thing, it just never closes. What on earth can I do with this? It´s driving me grazy!


  • Answer selected by SQ_AM at 06-08-2025, 09:30.
    SQ_AM
    Junior Member
    • Jul 2025
    • 3

    This is solved now. The script gave result 1 even there was no files in the folder. We deleted the Error folder from the server and created it again, after that the script gave result 0. Now the alarm works correctly. Very mystical thing....

    Comment

    • Markku
      Senior Member
      Zabbix Certified SpecialistZabbix Certified ProfessionalZabbix Certified Expert
      • Sep 2018
      • 1781

      #2
      Can you show the relevant configurations?

      Markku

      Comment

      • SQ_AM
        Junior Member
        • Jul 2025
        • 3

        #3
        What configuration you mean? The template config?



        Item
        Click image for larger version

Name:	image.png
Views:	65
Size:	23.5 KB
ID:	505244
        Trigger has an expression

        last(/Solteq template File Check/FileCount[{#ERRORPATH}])>0​

        On the app server we have a scheduled task which runs this script every day, this creates list of folders we want to monitor

        Click image for larger version

Name:	image.png
Views:	41
Size:	35.6 KB
ID:	505247
        The agent has user parameters
        UserParameter=FileCount[*],cscript C:\Zabbix2\scripts\FileCount.vbs //nologo "$1"
        UserParameter=Folder.Discovery,powershell -NoProfile -ExecutionPolicy Bypass -File "C:\Zabbix2\scripts\ReadFileList.ps1"

        Click image for larger version

Name:	image.png
Views:	41
Size:	20.0 KB
ID:	505245
        Click image for larger version

Name:	image.png
Views:	42
Size:	24.2 KB
ID:	505246

        This template has been working fine and it works in this host with all other folders but when file comes to \\SAF\\El\\Error path, the alarm won´t close even there is no files in that path. In any other path it works fine.


        Click image for larger version

Name:	image.png
Views:	41
Size:	44.7 KB
ID:	505248

        Comment

        • Markku
          Senior Member
          Zabbix Certified SpecialistZabbix Certified ProfessionalZabbix Certified Expert
          • Sep 2018
          • 1781

          #4
          Trigger has an expression

          last(/Solteq template File Check/FileCount[{#ERRORPATH}])>0
          If you say that the problem does not clear, it means that the item either still receives a positive integer, or there is no new value at all. See the latest values data and the timestamps for the item to see what is happening. Zabbix server/proxy/agent log is also useful if there is something unexpected happening with the item.

          Markku

          Comment

          • SQ_AM
            Junior Member
            • Jul 2025
            • 3

            #5
            This is solved now. The script gave result 1 even there was no files in the folder. We deleted the Error folder from the server and created it again, after that the script gave result 0. Now the alarm works correctly. Very mystical thing....

            Comment

            Working...