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

Zabbix agent item key system.stat[ent] cannot end successful

    Details

    • Team:
      Team A
    • Sprint:
      Sprint 10, Sprint 11, Sprint 12
    • Story Points:
      3.4

      Description

      Here we have two condition blocks. The first one to handle system.stat item keys with a single argument only (exclusively "ent" right now). The second condition block is to handle all related item keys having two arguments.
      The problem is, that even if everything went well for the single argument item key in the first condition block, the second block is still run through. Since "ent" does not exist as valid first argument here, we end up in the else clause returning an error:

              [...]
              if (0 == strcmp(section, "ent"))
              {
                              [...]
                              SET_DBL_RESULT(result, collector->vmstat.ent);
              }
              [...]
              
              if (0 == strcmp(section, "kthr"))
              [...]
              else
              {
                      SET_MSG_RESULT(result, zbx_strdup(NULL, "Invalid first parameter."));
                      return SYSINFO_RET_FAIL;
              }
      
              return SYSINFO_RET_OK;
      }
      

      PS: The issue is likely existent in other releases as well.

      PPS: this issue might duplicate ZBX-3049 resp. ZBX-5186. Feel free to close it as such, if this is the case.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                okkuv9xh Marc
              • Votes:
                1 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: