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

PMM 1 mongo_exporter does not support authorization for MongoDB 5.0

Details

    • Bug
    • Status: Open
    • Medium
    • Resolution: Unresolved
    • 1.17.1, 1.17.4
    • None
    • MongoDB_Exporter
    • None

    Description

      Our compatibility matrix states PMM 1 supports MongoDB 5.0. But it seems the mongo_exporter bundled with PMM 1 server/client uses a MongoDB Go driver version which does not support authorization for connections to MongoDB 5.0. 

      The following error appears:

      ./mongodb_exporter -mongodb.uri="mongodb://mongodb_exporter:[email protected]:27017/admin" -test
      
      ERRO[0000] Cannot connect to server using url mongodb://****:****@localhost:27017: server returned error on SASL authentication step: BSON field 'saslContinue.mechanism' is an unknown field.  source="connection.go:84"
      ERRO[0000] Can't connect to MongoDB: Cannot connect using uri: mongodb://mongodb_exporter:[email protected]:27017/admin  source="mongodb_exporter.go:104"
      

      If no login/password is specified, it can connect:

      ./mongodb_exporter -mongodb.uri="mongodb://localhost:27017/admin" -test
      
      {
        "Version": "5.0.5",
        "VersionArray": [
          5,
          0,
          5,
          0
        ],
        "GitVersion": "d65fd89df3fc039b5c55933c0f71d647a54510ae",
        "OpenSSLVersion": "",
        "SysInfo": "",
        "Bits": 64,
        "Debug": false,
        "MaxObjectSize": 16777216
      }
      

      It seems the necessary changes were made in MongoDB Go driver 1.4.0 with commit https://github.com/mongodb/mongo-go-driver/commit/5d11dfab990acb6259bcaa6973af706d9403975d

      The node_exporter in PMM 1 client should be updated to fully support MongoDB 5.0

      Attachments

        Activity

          People

            Unassigned Unassigned
            maksim.larin Maksim Larin (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Smart Checklist