Uploaded image for project: 'Percona Monitoring and Management'
  1. Percona Monitoring and Management
  2. PMM-6927

A metric for oldest oplog timestamp into mongodb_exporter v0.20+

Details

    • Bug
    • Status: Open
    • Medium
    • Resolution: Unresolved
    • None
    • None
    • MongoDB_Exporter
    • Yes
    • Yes
    • C/S Core

    Description

      An important monitoring metrics for MongoDB is the "oplog window", which is the time between the current oldest document in the capped oplog collection and the latest.

      The latest doesn't need to be fetched necessarily - it will be approximately the same as current clock time, and is also reflected in the replset member metrics named "optime".

      Can we add a "mongodb_oplog_timestamp_oldest" metric to mongodb_exporter. It would be fetched with it's own query (see below for mongo shell equivalent), which seems a bit extravagant for the sake of one metric but there is a lot of value to DBAs to know where the end of the oplog is.

      db.getSiblingDB("local").oplog.rs.find({}, {ts: true}).sort({"ts": 1}).limit(1)
      

      Once the mongodb_exporter has the metric the "Oplog Recovery Window" graph in the MongoDB Replset Summary dashboard should be updated to use it instead of the "mongodb_mongod_replset_oplog_tail_timestamp" metric that was in the older mongodb_exporter. And/or add "mongodb_mongod_replset_oplog_tail_timestamp" as alias metric that appears if compatibility mode is on.

      Attachments

        Activity

          People

            Unassigned Unassigned
            akira.kurogane Akira Kurogane (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Smart Checklist