Ad Widget

Collapse

Unable to delete hosts or unlink templates after discovery...

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Alfista
    Senior Member
    • Mar 2017
    • 136

    #1

    Unable to delete hosts or unlink templates after discovery...

    Hi,

    i have use discovery for finding hosts in my network in Zabbix Appliance 3.4.8. After that I have added the template Linux SNMPv2. And there started the problems. On some hosts the Template find about 6000 Items and on some normal count (about 200).
    After that I tried to remove the template (unlink with clear data), then delete the host but nothing will work.

    Please can you help me with these problems:
    1. how to unlink the template with clearing the data (standard template unlink with clear data in host settins doesn't work), that I don't have there so many items and I don't overload the zabbix server?
    2. how to delete host with so many items (standard delete in host tab doesn't work)?
    3. can some one explore me why the Linux SNMPv2 Template - HOST-RESOURCES-MIB SNMPv2 has generate by discovery so many items on one linux system and on on other it find excat the actual count of items and how to limit it, that it doesn't make these problems? The problem is exactly in memory Discovery and vm.memory function. It found there abourt 1000 memories and added to each 4 items, then the CPU where it found more CPU's (cores), but this isnt so bad, while it looks that it generated items to HT pipelines.

    Thanks for helps.
  • aigars.kadikis
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Mar 2018
    • 208

    #2
    Hi,

    Are these 6000 items mainly in a supported state? Are you able to remove one of them manually? What Applications category has assigned for the most of these 6000 items?

    3. There are three discovery rules in 'Template Module HOST-RESOURCES-MIB SNMPv2' - storage, memory, CPU. You need to work with Filter section and create some exclusion rules to decrease the item count in one of your servers.
    Click image for larger version

Name:	exclude-storege-devices.png
Views:	2285
Size:	60.1 KB
ID:	359167
    After you set new exclusion filters then please set temporary 'keep lost resource period' to 0.
    and decrease your discovery rule 'Update interval' (for example to 10m) just to take faster effect.

    Can you clarify which discovery rule has generated so many items in your situation?

    2. I hope the third point will solve the second one.

    Regards,

    Comment

    • Alfista
      Senior Member
      • Mar 2017
      • 136

      #3
      Hi Aigars,

      yes 80% are fuly active and the others are calculated and some of them are unsuported while division by zero.
      Yes im able to remove manualy item by item. On one I have done it and needed a half day for it :-(.
      It has added the Template - HOST-RESOURCES-MIB SNMPv2, the Application Memory and teh Memory Discovery Rule and the Discovery items in it. All was preinstalled in Zabbix.

      The filters are set as it was created in Zabbix:

      Click image for larger versionName:	Filters.jpgViews:	1Size:	54.9 KBID:	359174

      Where should I set the 'keep lost resource period'?

      Yes, as I wrote above it is the Memory Discovery rule. I dont know hy it has find so many memories, when in older version when I had installed it was OK and in this devices are not so many memories ...

      Thanks.

      Comment

      • aigars.kadikis
        Senior Member
        Zabbix Certified SpecialistZabbix Certified Professional
        • Mar 2018
        • 208

        #4
        Originally posted by Alfista
        Hi Aigars,

        yes 80% are fuly active and the others are calculated and some of them are unsuported while division by zero.
        Yes im able to remove manualy item by item. On one I have done it and needed a half day for it :-(.
        It has added the Template - HOST-RESOURCES-MIB SNMPv2, the Application Memory and teh Memory Discovery Rule and the Discovery items in it. All was preinstalled in Zabbix.

        The filters are set as it was created in Zabbix:

        Click image for larger versionName:	Filters.jpgViews:	1Size:	54.9 KBID:	359174

        Where should I set the 'keep lost resource period'?

        Yes, as I wrote above it is the Memory Discovery rule. I dont know hy it has find so many memories, when in older version when I had installed it was OK and in this devices are not so many memories ...

        Thanks.
        'keep lost resource period' can be found under tab [Discovery Rule]. Please show some item key names which is in supported state and which you would like to not include in monitoring.
        Please include the screen which contains error message 'division by zero'.

        Comment

        • Alfista
          Senior Member
          • Mar 2017
          • 136

          #5
          Hi Aigars,

          here are the screen shots:

          Click image for larger versionName:	Items.jpgViews:	1Size:	80.4 KBID:	359179

          Click image for larger versionName:	Item-settings.jpgViews:	1Size:	68.8 KBID:	359180

          Comment

          • aigars.kadikis
            Senior Member
            Zabbix Certified SpecialistZabbix Certified Professional
            • Mar 2018
            • 208

            #6
            Originally posted by Alfista
            Hi Aigars,

            here are the screen shots:

            Click image for larger versionName:	Items.jpgViews:	1Size:	80.4 KBID:	359179

            Click image for larger versionName:	Item-settings.jpgViews:	1Size:	68.8 KBID:	359180

            Please list the STORAGE_TYPE on the host where you have a lot of items:
            Code:
            snmpwalk -v 2c -c public localhost:161 .1.3.6.1.2.1.25.2.3.1

            Comment

            • Alfista
              Senior Member
              • Mar 2017
              • 136

              #7
              Here is it.
              It was needed to yip it, while it has 0,5MB.

              It is a Linux system build on FreeBSD clang version 3.3 and on previous version of Zabbix 3.4.6 id doesn't create so many items.
              Attached Files
              Last edited by Alfista; 24-05-2018, 12:26.

              Comment

              • aigars.kadikis
                Senior Member
                Zabbix Certified SpecialistZabbix Certified Professional
                • Mar 2018
                • 208

                #8
                We can discover and include description in discovery. This can be done by replacing your discovery rule SNMP OID from
                Code:
                 discovery[{#SNMPVALUE},1.3.6.1.2.1.25.2.3.1.3,{#ALLOC_UNITS},1.3.6.1.2.1.25.2.3.1.4,{#STORAGE_TYPE},1.3.6.1.2.1.25.2.3.1.2]
                to
                Code:
                discovery[{#SNMPVALUE},1.3.6.1.2.1.25.2.3.1.3,{#ALLOC_UNITS},1.3.6.1.2.1.25.2.3.1.4,{#STORAGE_TYPE},1.3.6.1.2.1.25.2.3.1.2,{#STORAGE_DESCR},1.3.6.1.2.1.25.2.3.1.3]
                Click image for larger version

Name:	discovery-rule.png
Views:	2131
Size:	214.6 KB
ID:	359196

                and choose the most important things in HOST-RESOURCES-MIB::hrStorageDescr like 'Isilon_2576' and 'rl_entry'
                Click image for larger version

Name:	storage-descriptor-to-monitor.png
Views:	2166
Size:	133.7 KB
ID:	359197

                Regards,

                Comment

                • aigars.kadikis
                  Senior Member
                  Zabbix Certified SpecialistZabbix Certified Professional
                  • Mar 2018
                  • 208

                  #9
                  Sorry, but now i think the better way would be to work with hrStorageSize. Please test out this discovery:
                  Code:
                  discovery[{#SNMPVALUE},1.3.6.1.2.1.25.2.3.1.3,{#ALLOC_UNITS},1.3.6.1.2.1.25.2.3.1.4,{#STORAGE_TYPE},1.3.6.1.2.1.25.2.3.1.2,{#STORAGE_SIZE},.1.3.6.1.2.1.25.2.3.1.5]
                  and set regex as:
                  Code:
                  ^[1-9][0-9]*$
                  Click image for larger version

Name:	storage-size.png
Views:	2144
Size:	90.7 KB
ID:	359199 ​​​​​​​

                  Regards,

                  Comment

                  • Alfista
                    Senior Member
                    • Mar 2017
                    • 136

                    #10
                    OK and what it will do?
                    It will filter the received data to have only the needed and not all?
                    The 2nd filter fill show only info which doesn't have 0MB? And in the 1st it will be released to the Isilon in description?

                    I don't fully understand it. The filter based on size is OK but the 1st based on description not. There will not have all items description Isilon when they are from Isilon?

                    Thanks for exploration.

                    Comment

                    • aigars.kadikis
                      Senior Member
                      Zabbix Certified SpecialistZabbix Certified Professional
                      • Mar 2018
                      • 208

                      #11
                      Originally posted by Alfista
                      OK and what it will do?
                      It will filter the received data to have only the needed and not all?
                      The 2nd filter fill show only info which doesn't have 0MB? And in the 1st it will be released to the Isilon in description?

                      I don't fully understand it. The filter based on size is OK but the 1st based on description not. There will not have all items description Isilon when they are from Isilon?

                      Thanks for exploration.
                      As you said the second filter will exclude all items which has StorageSize 0 (in other words: which is bigger than zero)
                      The first rule is based on description and yes - it not very usefull this time.

                      There are also such a thing like StorageUsed with numeric address .1.3.6.1.2.1.25.2.3.1.6
                      Please consider compare StorageUsed with 0. This would generate more items than in case of 'StorageSize'.

                      Discovery:
                      Code:
                      discovery[{#SNMPVALUE},1.3.6.1.2.1.25.2.3.1.3,{#ALLOC_UNITS},1.3.6.1.2.1.25.2.3.1.4,{#STORAGE_TYPE},1.3.6.1.2.1.25.2.3.1.2,{#STORAGE_USED},1.3.6.1.2.1.25.2.3.1.6]
                      Filter:
                      Code:
                      {#STORAGE_USED} = ^[1-9][0-9]*$
                      I believe one of those exclusions can eliminate message 'division by zero'.

                      Let us know how it goes.

                      Regards,

                      Comment

                      • Alfista
                        Senior Member
                        • Mar 2017
                        • 136

                        #12
                        Ok and the macro should be:
                        {#STORAGE_USED} or as above {#STORAGE_SIZE} ?

                        Comment

                        • aigars.kadikis
                          Senior Member
                          Zabbix Certified SpecialistZabbix Certified Professional
                          • Mar 2018
                          • 208

                          #13
                          Originally posted by Alfista
                          Ok and the macro should be:
                          {#STORAGE_USED} or as above {#STORAGE_SIZE} ?
                          Like in discovery string mentioned we are going with {#STORAGE_USED} scenario.

                          Regards,

                          Comment


                          • Alfista
                            Alfista commented
                            Editing a comment
                            OK changed. Will see what happens.

                          • Alfista
                            Alfista commented
                            Editing a comment
                            Nothing changed. The result is the same. Added above 4000 items and also the with 0 too.
                        • aigars.kadikis
                          Senior Member
                          Zabbix Certified SpecialistZabbix Certified Professional
                          • Mar 2018
                          • 208

                          #14
                          Would you mind to share how you configured the discovery rule and the filter tab?

                          Comment

                          • Alfista
                            Senior Member
                            • Mar 2017
                            • 136

                            #15
                            Of course.

                            In the Discovery rule i have changed the SNMP OID as you sent me:

                            Code:
                            discovery[{#SNMPVALUE},1.3.6.1.2.1.25.2.3.1.3,{#ALLOC_UNITS},1.3.6.1.2.1.25.2.3.1.4,{#STORAGE_TYPE},1.3.6.1.2.1.25.2.3.1.2,{#STORAGE_USED},1.3.6.1.2.1.25.2.3.1.6]
                            And here are the screen shots:

                            Click image for larger version  Name:	Discovery.png Views:	1 Size:	212.9 KB ID:	359439
                            Click image for larger version  Name:	Filter.png Views:	1 Size:	78.8 KB ID:	359440

                            I don't fully understand it. On other Linux PC it works correctly, only this one not.

                            Comment


                            • Alfista
                              Alfista commented
                              Editing a comment
                              And I found that this last template doesn't show the founded memory storages as the old one, with the correct names, that it can be better identified.
                          Working...