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

MongoDB plugin starts to timeout after some time

XMLWordPrintable

    • Sprint 92 (Sep 2022)
    • 1.5

      Summary:
      I started to use the new MongoDB plugin.
      Everything works fine for several hours, then after a while I get only "ZBX_NOTSUPPORTED: timeout occurred".
      I have to restart the zabbix agent to get it working again.

       

      My environment:

      • Zabbix Agent 2 version: 6.2.0
      • MongoDB plugin version: 1.0.0 (branch: master, commit: 21d652197aba9a54f4af45424a8d2ef98f5539b4)

       

      (Faster) Reproduction:
      It is possible to reproduce the bug in a few seconds/minutes by spamming the 'mongodb.server.status' requests:

      while [ 1 ]; do
        zabbix_get -s 127.0.0.1 -p 10050 -k 'mongodb.server.status["tcp://localhost:27017","XXX","XXX"]' || break;
      done

       

      Details:
      Once the bug occurs once, it occurs for all subsequent requests (even when testing the URI of another mongodb server).

      $ zabbix_get -s 127.0.0.1 -p 10050 -k 'mongodb.server.status["tcp://localhost:27017","XXX","XXX"]'
      ZBX_NOTSUPPORTED: timeout occurred
      $ zabbix_get -s 127.0.0.1 -p 10050 -k 'mongodb.server.status["tcp://another.working.mongodb:27017","YYY","YYY"]'
      ZBX_NOTSUPPORTED: timeout occurred
      $ zabbix_get -s 127.0.0.1 -p 10050 -k 'agent.hostname'
      my-hostname 

      Note: this only concerns the metrics of MongoDB plugin, the others continue to work.
      Also these metrics work fine if I try them at the same time on another zabbix agent that hasn't encountered the bug yet.

      Problem, when I set "DebugLevel=5" I can't reproduce the bug anymore (maybe it's a concurrency bug and logging takes enough time to reduce the probability of it occurring?).
      And I can reproduce again immediately when I reset to "DebugLevel=3".

            esneiders Eriks Sneiders
            nathan818 Nathan
            Team INT
            Votes:
            6 Vote for this issue
            Watchers:
            15 Start watching this issue

              Created:
              Updated:
              Resolved: