Ad Widget

Collapse

Extension to Zabbix discovery [zbxlld]

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • skarllot
    Junior Member
    • Oct 2011
    • 21

    #16
    Originally posted by aib
    Hello!

    I just downloaded version 0.6 and try to use it.
    1) file zbxlld-win.exe copied into c:\zabbix_agent
    2) UserParameters added to zabbix_agentd.win.conf
    UserParameter=zbxlld[*],C:\Zabbix_Agent\zbxlld-win.exe $1 $2 $3
    3) I try to test it from command line

    . . .

    Do I have to use the different syntax for commands which threw an exception?
    Which version of Windows are you using?
    Can you send me the value of the key "Counter" into "SOFTWARE\Microsoft\Windows NT\CurrentVersion\Perflib\009"?
    Last edited by skarllot; 07-02-2014, 16:39.

    Comment

    • aib
      Senior Member
      • Jan 2014
      • 1615

      #17
      I use Windows 7 64 bit
      Code:
      C:\ ver
      
      Microsoft Windows [Version 6.1.7601]
      
      C:\
      This is the full text of exception.

      Code:
      [root@zabbix ~]# zabbix_get -s 10.1.10.137 -k zbxlld[drive.discovery.fixed]
      
      Unhandled Exception: System.TypeInitializationException: The type initializer for 'zbxlld.Windows.Supplement.PerfMon.LogicalDisk' threw an exception. ---> System.TypeInitializationException: The type initializer for 'zbxlld.Windows.Supplement.PerfMon.Localization' threw an exception. ---> System.ArgumentException: An item with the same key has already been added.
         at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
         at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
         at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
         at zbxlld.Windows.Supplement.PerfMon.Localization..cctor()
         --- End of inner exception stack trace ---
         at zbxlld.Windows.Supplement.PerfMon.Localization.GetName(String id)
         at zbxlld.Windows.Supplement.PerfMon.LogicalDisk..cctor()
         --- End of inner exception stack trace ---
         at zbxlld.Windows.Supplement.PerfMon.LogicalDisk.GetInstanceName(Guid guid)
         at zbxlld.Windows.Discovery.Drive.GetOutput(String key)
         at zbxlld.Windows.MainClass.Main(String[] args)
      [root@zabbix ~]#
      Sincerely yours,
      Aleksey

      Comment

      • aib
        Senior Member
        • Jan 2014
        • 1615

        #18
        This is the the value of the key "Counter" into "SOFTWARE\Microsoft\Windows NT\CurrentVersion\Perflib\009" was posted on 009.txt

        Sorry, I cannot do it here because it's almost 100k when I can post only 50k of text.
        Sincerely yours,
        Aleksey

        Comment

        • skarllot
          Junior Member
          • Oct 2011
          • 21

          #19
          Originally posted by aib
          I use Windows 7 64 bit
          Code:
          C:\ ver
          
          Microsoft Windows [Version 6.1.7601]
          
          C:\
          This is the full text of exception.

          Code:
          [root@zabbix ~]# zabbix_get -s 10.1.10.137 -k zbxlld[drive.discovery.fixed]
          
          Unhandled Exception: System.TypeInitializationException: The type initializer for 'zbxlld.Windows.Supplement.PerfMon.LogicalDisk' threw an exception. ---> System.TypeInitializationException: The type initializer for 'zbxlld.Windows.Supplement.PerfMon.Localization' threw an exception. ---> System.ArgumentException: An item with the same key has already been added.
             at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
             at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
             at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
             at zbxlld.Windows.Supplement.PerfMon.Localization..cctor()
             --- End of inner exception stack trace ---
             at zbxlld.Windows.Supplement.PerfMon.Localization.GetName(String id)
             at zbxlld.Windows.Supplement.PerfMon.LogicalDisk..cctor()
             --- End of inner exception stack trace ---
             at zbxlld.Windows.Supplement.PerfMon.LogicalDisk.GetInstanceName(Guid guid)
             at zbxlld.Windows.Discovery.Drive.GetOutput(String key)
             at zbxlld.Windows.MainClass.Main(String[] args)
          [root@zabbix ~]#
          Please try using the version 0.6.1.

          Comment

          • aib
            Senior Member
            • Jan 2014
            • 1615

            #20
            Sorry for silly question - where I can get the newest version?
            https://github.com/skarllot/zbxlld/wiki has only version 0.6
            Sincerely yours,
            Aleksey

            Comment

            • skarllot
              Junior Member
              • Oct 2011
              • 21

              #21
              Originally posted by aib
              Sorry for silly question - where I can get the newest version?
              https://github.com/skarllot/zbxlld/wiki has only version 0.6
              I was updated only the History page. Now the How to Install from version 0.6 was updated too.

              Comment

              • aib
                Senior Member
                • Jan 2014
                • 1615

                #22
                Sorry about that.
                It works. partly.
                Code:
                [root@zabbix ~]# zabbix_get -s 10.1.10.137 -k zbxlld[drive.discovery.fixed]
                
                Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
                   at zbxlld.Windows.Supplement.JsonOutput.GetOutput(String keySuffix)
                   at zbxlld.Windows.MainClass.Main(String[] args)
                [root@zabbix ~]#
                [root@zabbix ~]# zabbix_get -s 10.1.10.137 -k zbxlld[drive.discovery.mounted]
                
                Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
                   at zbxlld.Windows.Supplement.JsonOutput.GetOutput(String keySuffix)
                   at zbxlld.Windows.MainClass.Main(String[] args)
                [root@zabbix ~]# 
                [root@zabbix ~]# zabbix_get -s 10.1.10.137 -k zbxlld[drive.discovery.swap]
                {"data": [
                        {
                                "{#FSNAME}":"C:\\",
                                "{#FSPERFMON}":"C:",
                                "{#FSLABEL}":"",
                                "{#FSFORMAT}":"NTFS",
                                "{#FSCAPTION}":"C:"
                        }
                ] }
                [root@zabbix ~]#
                Sincerely yours,
                Aleksey

                Comment

                • skarllot
                  Junior Member
                  • Oct 2011
                  • 21

                  #23
                  Originally posted by aib
                  Sorry about that.
                  It works. partly.
                  . . .
                  I compiled new version into debug mode. Please download that and send me the generated log.
                  Download: goo . gl / tfe5xx

                  Comment

                  • skarllot
                    Junior Member
                    • Oct 2011
                    • 21

                    #24
                    Originally posted by aib
                    Sorry about that.
                    It works. partly.
                    . . .
                    I've done some improvements and compiled. Please download and send me the generated log.
                    Download goo . gl / sD83GX

                    Comment

                    • yix
                      Junior Member
                      • Jun 2014
                      • 2

                      #25
                      Hi, Can you share a example template to use with zbxlld? Thanks.

                      Comment

                      • yix
                        Junior Member
                        • Jun 2014
                        • 2

                        #26
                        Gentlemen, how do you do service discovery? Particularly how do you create item prototypes?

                        For example discovery rule key is: zbxlld[service.discovery.auto]
                        What should be in key field of an item prototype to get service status?

                        Thanks.

                        Comment

                        • alfsolli
                          Junior Member
                          Zabbix Certified Trainer
                          Zabbix Certified Specialist
                          • Aug 2010
                          • 19

                          #27
                          Template example

                          Hi.

                          I've attached a template that uses LLD to discover services with zbxlld.
                          There are a bunch of static items and triggers there as well, so please ignore those.
                          Also, I haven't tried importing it, so I don't take take any blame for dead goldfishes etc you might experience.

                          It'll discover any service set to startup type = automatic, and alert if any of those has been anything but running for 5 minutes.

                          Hope this helps anyone.
                          Attached Files

                          Comment

                          • smccloud
                            Junior Member
                            • Aug 2015
                            • 2

                            #28
                            I'm using your template as a basis to create my own. When I try to add a trigger for a service not running I get
                            Code:
                            Incorrect item key "service_state[{#SVCNAME}]" provided for trigger expression on "blah Template".
                            The trigger expression I am trying to make is
                            Code:
                            {GeoComm Template:service_state[{#SVCNAME}].last(0)}#0

                            Comment

                            Working...