This is a Collection Agent plugin that gathers data from MongoDB. This plugin allows you to get an overview of database operations, such as:
- Track the current state of database.
- View reports of asserts on the database.
- Monitor the metrics for write performance.
- View contains storage statistics for a given database.
- Check reports information regarding the state and use of indexes in MongoDB.
The MongoDB plugin supports Collection Agent publication into Geneos using dynamic Managed Entities. Setting up this plugin in Geneos involves these primary steps:
Configure your mappings.
Configure your other Dynamic Entities in the Gateway. See Create Dynamic Entities in Collection Agent setup for a more detailed procedure.
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.
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>
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