MongoDB

Overview Copied

This is a Collection Agent plugin that gathers data from MongoDB. This plugin allows you to get an overview of database operations, such as:

Configure Geneos to deploy the MongoDB plugin Copied

The MongoDB plugin supports Collection Agent publication into Geneos using dynamic Managed Entities. Setting up this plugin in Geneos involves these primary steps:

  1. Set up your Collection Agent plugin.

  2. Configure your mappings.

  3. Configure your other Dynamic Entities in the Gateway. See Create Dynamic Entities in Collection Agent setup for a more detailed procedure.

Set up your Collection Agent plugin Copied

Setting up your collector in the Gateway Setup Editor by adding the following configuration in Dynamic Entities > Collectors. For more information, see Collectors in Dynamic Entities.

Configuration Reference Copied

collectors:
  - name: mongodb
    type: plugin
    class-name: MongoDbCollector

    # Connection details
    connection:
      # The machine where mongod or mongos is running. (required)
      host: localhost

      # Port where the MongoDB Server is listening. (required)
      port: 27017

      # Specifies the name of the database to connect to. (required)
      database: test

      # Create a credential that will authenticate using the default authentication mechanism
      # (optional, default is connecting without authentication)
      authentication:
        # Username used to connect to the database. User should have at least 'clusterMonitor' role. (required)
        user: <database user>

        # Password of the said username (required)
        password: <database password>

        # MongoDB database that contains your user's authentication data (optional, default is specified in database.)
        auth-db: <database>

      # Connect to a MongoDB instance using TLS
      # (optional, default is connecting without tls)
      tls:
        # The path to a CA PEM file that contains the CA certificate. (required)
        caFile: <path to CA PEM file>

        # The path to a Client certificate. (optional)
        # The mongod/mongos does not require a certificate key file from the client to verify the client's identity.
        # If mongod/mongos is configured with Client Certificate Validation, clientCert and clientKey must be supplied.
        clientCert: <path to Client Certificate>

        # The path to a Client Key PEM File. It should be in PKCS#8 format. (optional)
        clientKey: <path to Client Key PEM file>

How to convert Client Key file to PKCS#8 format Copied

The default format of the openssl genrsa output is in PKCS#1. To convert it to PCKS#8, execute the command:

openssl pkcs8 -topk8 -inform PEM -outform PEM -in client.key -out clientKey.pem -nocrypt
["Geneos"] ["Geneos > Netprobe"] ["User Guide"]

Was this topic helpful?