Uploaded image for project: 'MongoDB Database Tools'
  1. MongoDB Database Tools
  2. TOOLS-368

Mongotop is listing more than 1000 ms of total work per second

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: mongotop
    • None

      Mongotop is measuring more than 1000 ms of work per second.

      This is a problem because it makes it look like mongotop is malfunctioning.

      Steps to reproduce:

      • Run a mongod & mongo & mongotop, all 2.8.0-rc0
      • In mongo shell, run the following:

      db.testcol.drop()
      for (i=1; i<=10000; i++) {
      arr = [];
      for (j=1; j<=1000; j++) {
      doc =

      { _id : (1000 * (i-1) + j), a : i, b : j, c : (1000 * (i-1)+ j)}

      ;
      arr.push(doc)
      };
      db.testcol.insert(arr);
      var x = db.testcol.find(

      { b : 255 }

      );
      x.next();
      var x = db.testcol.find(

      { _id : 1000 * (i-1) + 255 }

      );
      x.next();
      var x = "asdf";
      db.testcol.update(

      { a : i, b : 255 }

      , { $set :

      { d : x.pad(1000) }

      });
      print
      }

      • Give it a minute or two to really slow down.
      • Look at mongotop

      Expected result:

      <1000 ms of activity per second

      Actual result:

      > 1000 ms of activity per second (by a little)

      See attached.

            Assignee:
            Unassigned Unassigned
            Reporter:
            william.cross William Cross
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: