Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-24224

Incorrect number of items in "Administration" -> "Proxies"

XMLWordPrintable

    • Icon: Problem report Problem report
    • Resolution: Unresolved
    • Icon: Trivial Trivial
    • None
    • 6.4.12
    • None

      We have 14 proxies in the environment. In the "administration" -> "Proxies" tab we have an incorrect number of per proxy items. For readability - we will focus on a single proxy (the wrong number is on all proxies).
      In the proxy tab we have:

      Name Mode Encryption Version Last seen (age) Host count Item count Required vps Hosts
      ProxyXXX Active None 6.4.4 2s 2004 1898 539.26 xxx,xxx,xxx,xxx......

      The number of hosts is correct, but the number of items (1898) is definitely too small. Additionally - "Required vps" seems to be ok.

      We started the debug by checking the query "GUI -> server" by tcpdump, as proxy status data is taken directly form servers trapper process. The answer has been shortened to include the most important information:

      (...)
      "item stats": [
      (...)
        {
                      "attributes": {
                          "proxyid": 30913,
                          "status": 1
                      },
                      "count": 17
                  },
                  {
                      "attributes": {
                          "proxyid": 30913,
                          "status": 0,
                          "state": 1
                      },
                      "count": 57
                  },
                  {
                      "attributes": {
                          "proxyid": 30913,
                          "status": 0,
                          "state": 0
                      },
                      "count": 1841
                  },
            (...)
            ] (...)

      Of course, 1841 + 57 = 1898, which agrees with the above number of items (from proxies tab). So we have ruled out a problem on the GUI side.

       

      We then checked the configuration on the proxy side. in short - We noticed the correct value in the logs when increasing the debug level:

      (...)
      411987:20240314:111800.365 DCsync_configuration() items      : 396984 (1760203 slots)
      411987:20240314:111800.365 DCsync_configuration() items_hk   : 396984 (1760203 slots)
      411987:20240314:111800.365 DCsync_configuration() numitems   : 338924 (1760203 slots)
      (...)

      So we assumed correct "server <-> proxy" communication and we have ruled out a problem on the PROXY side.

       

      Returning to the "GUI -> server" communication, the response returns wrong values, so we suspect an error on the zabbix-server side, and in particular - communication with the cache.
      After a quick review of the code, we suspect the dc_status_update() function in the dbconfig.c file, where, for example, you can see the counting of the number of items:

      (...)
      if (NULL != dc_proxy_host)
      dc_proxy_host->items_active_normal++;
      (...)
      if (NULL != dc_proxy_host)
      dc_proxy_host->items_active_notsupported++;
      (...)

       

      Unfortunately, these are just suspicions and we are not sure where the error is.

            mkudlacz Michal Kudlacz
            aprzybylski Albert Przybylski
            Votes:
            7 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated: