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

cmdline option does not filter result for proc.num and proc.mem on FreeBSD<8.3

XMLWordPrintable

    • Sprint 92 (Sep 2022)
    • 1

      Steps to reproduce:

      1. Use FreeBSD 8.2 or earlier
      2. Use agent 4.0.31, 5.0.12, 5.2.7, 5.4.1, 6.0.0 or older
      3. Specify any cmdline value for proc.num[] or proc.mem[]
      # ps ax -o user,command | grep syslogd
      root /usr/sbin/syslogd -ss
      # zabbix_get -s 127.0.0.1 -k 'proc.num[syslogd,root]'
      1

      Result:
      Returned 0.

      FreeBSD 7.4, 8.2; zabbix_agentd 5.4.1:

      # zabbix_get -s 127.0.0.1 -k 'proc.num[syslogd,root,,s$]'
      0

      Expected:
      Not 0.

      FreeBSD 8.3, 9.0; zabbix_agentd 5.4.1:

      # zabbix_get -s 127.0.0.1 -k 'proc.num[syslogd,root,,s$]'
      1

      As far as I can tell, the solution to ZBX-19139 affected the get_commandline() function in proc.c on older versions of FreeBSD.

      FreeBSD 7.4, 8.2; zabbix_agentd 5.4.0:

      # zabbix_get -s 127.0.0.1 -k 'proc.num[syslogd,root,,s$]'
      1

            jlambda Juris Lambda
            olorin Vyacheslav Terekhov
            Team B
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: