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

MongoDB exprorter doesn't show version for mongos intstance

Details

    • Bug
    • Status: Done
    • Medium
    • Resolution: Fixed
    • None
    • 2.34.0
    • None
    • None
    • 1
    • Yes
    • Yes
    • No
    • [obsolete] Observability
    • Hide

      described in issue

      Show
      described in issue

    Description

      Steps to reproduce:

      1. Run Shard with mongos instance (you can use this docker compose file https://github.com/percona/mongodb_exporter/blob/main/docker-compose.yml#L156 to run it locally)
      2. Run mongodb_exporter and connect it to mongos instance (For example
        ./mongodb_exporter --mongodb.uri=mongodb://localhost:17000 --collector.replicasetstatus=true --log.level=debug --collect-all --web.listen-address=:9219 --compatible-mode=true
        

        )

      3. open metrics page (in this case http://localhost:9219/metrics)
      4. find metric `mongodb_version_info`

      Expected result
      In this case in the label `mongodb` version you can see mongo version (for example

      mongodb_version_info{mongodb="4.2.23"} 1
      

      )

      Actual result
      You can see this:

      mongodb_version_info{mongodb="server version is unavailable"} 1
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            dmytro.liakhov Dmytro Liakhov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 4 hours
                4h
                Remaining:
                Time Spent - 3 hours Remaining Estimate - 1 hour
                1h
                Logged:
                Time Spent - 3 hours Remaining Estimate - 1 hour
                3h

                Smart Checklist