Ad Widget

Collapse

Prevent item delete "The item is not discovered anymore and will be deleted"

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Oigres
    Junior Member
    • Feb 2019
    • 3

    #1

    Prevent item delete "The item is not discovered anymore and will be deleted"

    Hello.

    Im new with zabbix and i have a question.

    I use auto discovery and now i made some changes and some items are not discovered anymore.

    I have a menssage in this items "The item is not discovered anymore and will be deleted", but i want to keep the data from this items to check the graphs.

    Any way to prevent this?

    Thank you.
  • Hernandes Martins
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Apr 2011
    • 900

    #2
    Hello,

    Maybe , Can you change the parameter " Keep lost resources period " in Discovery Rule, but I think not so good practices to storage data.
    __

    Att.
    Hernandes Martins - Zabbix Trainer

    Zabbix Brazil Partner - www.luniobr.com

    Zabbix Brazil Community - www.zabbixbrasil.org

    Blog: hernandesmartins.blogspot.com.br

    Skype: hernandss
    Telegram: @MrHernandes

    Español
    Facebook: facebook.com/groups/zabbixlatam
    Telegram: https://t.me/ZabbixEspañol

    Português
    Facebook: facebook.com/groups/zabbixbrasil/
    Telegram: https://t.me/ZabbixBrasil

    Comment

    • Oigres
      Junior Member
      • Feb 2019
      • 3

      #3
      Originally posted by Hernandes Martins
      Hello,

      Maybe , Can you change the parameter " Keep lost resources period " in Discovery Rule, but I think not so good practices to storage data.
      Thank you for your reply.

      I just want to keep some items, not all of them.

      Comment

      • charannaik
        Junior Member
        Zabbix Certified SpecialistZabbix Certified Professional
        • Dec 2014
        • 1

        #4
        The only alternative, (depending on the number discovered items / hosts) is to delete the unwanted items manually after increasing the "Keep lost resources period" value. Again, increasing the "Keep lost resource period" is not a good practice as Hernandes Martins already mentioned.

        Comment

        • Oigres
          Junior Member
          • Feb 2019
          • 3

          #5
          Originally posted by charannaik
          The only alternative, (depending on the number discovered items / hosts) is to delete the unwanted items manually after increasing the "Keep lost resources period" value. Again, increasing the "Keep lost resource period" is not a good practice as Hernandes Martins already mentioned.
          I was thinking on doing that.

          Whats is the best pratices in this case?

          Comment

          • monoterrible
            Junior Member
            • Feb 2024
            • 3

            #6
            Sorry if what I propose is stupid:
            Wouldn't running the discoveries associated with the host again resolve the issue? Thank you for the availability and good predisposition​

            Comment

            • PeterZielony
              Senior Member
              • Nov 2022
              • 146

              #7
              Originally posted by monoterrible
              Sorry if what I propose is stupid:
              Wouldn't running the discoveries associated with the host again resolve the issue? Thank you for the availability and good predisposition​
              No..He was asking to keep items that are no longer discovered by LLD indefinitely. Running discovery again would just discover what is available - items created before(by LLD) will be deleted after time specified in "Keep lost resource period" in LLD.

              Hiring in the UK? Drop a message

              Comment


              • monoterrible
                monoterrible commented
                Editing a comment
                muchas gracias, por la respuesta.
            • dimir
              Zabbix developer
              • Apr 2011
              • 1080

              #8
              In theory (haven't tested) you should be able to keep that item if you change the lastcheck field in the item_discovery table.

              Find out the itemid of your item (e. g. go to Configuration section, select host, items, right-click your item and Inspect the HTML code, it will be in data-itemid attribute), then go to your database and execute:
              Code:
              update item_discovery set lastcheck=unix_timestamp('2038-01-01') where itemid=<ITEMID>;

              Comment

              Working...