Configuring MongoDB Instances
- Updated2025-11-26
- 4 minute(s) read
Configure SystemLink Enterprise to access one or more remote MongoDB databases to enhance the scalability and the fault tolerance.
- You are upgrading from a SystemLink Enterprise version before 2023-10.
- You set global.mongodb.install to true.
For more information on migration conditions, refer to the release notes.
- If you are installing SystemLink Enterprise for the first time, provision the databases listed in the following table.
- Open systemlink-secrets.yaml.
-
Set the password for each database.
Note To use one set of credentials for all databases, you can leave the password field blank for each database.
Table 16. Configuration Parameters for a MongoDB Instance Service Database User Password alarmservice nialarm nialarm alarmservice.secrets.mongodb.servicePassword assetservice niapm niapm assetservice.secrets.mongodb.servicePassword comments comments nicomments comments.secrets.mongodb.servicePassword dataframeservice nidataframe nidataframe dataframeservice.secrets.mongodb.servicePassword fileingestion files files fileingestion.secrets.mongodb.servicePassword filescdc (optional) files files fileingestioncdc.secrets.mongodb.password feedservice nifeeds nifeeds feedservice.secrets.mongodb.servicePassword nbexecservice ninbexec ninbexec nbexecservice.secrets.mongodb.servicePassword notification ninotification ninotification notification.secrets.mongodb.servicePassword repository nirepo nirepo repository.secrets.mongodb.servicePassword routinescheduletrigger niroutinescheduletrigger niroutinescheduletrigger routinescheduletrigger.secrets.mongodb.servicePassword routineservice niroutines niroutines routineservice.secrets.mongodb.servicePassword saltmaster minions minions saltmaster.secrets.mongodb.minionsPassword saltmaster pillars pillars saltmaster.secrets.mongodb.pillarsPassword specificationmanagement (optional) specifications nispecificationmanagement specificationmanagement.secrets.mongodb.servicePassword systems nisystemsmanagement nisystems systems.secrets.mongodb.servicePassword systemsstate nisystemsstate nisystemsstate systemsstate.secrets.mongodb.servicePassword tags tags tags tags.secrets.mongodb.servicePassword taghistorian taghistorian taghistorian taghistorian.secrets.mongodb.servicePassword userdata niuserdata niuserdata userdata.secrets.mongodb.servicePassword userservices keyservices keyservice userservices.secrets.mongodb.keyServicePassword userservices users userservice userservices.secrets.mongodb.userServicePassword webappservices webapps webapps webappservices.secrets.mongodb.servicePassword workorder (optional) workorders niworkorder workorder.secrets.mongodb.servicePassword -
Determine the following by contacting NI support.
- The number of MongoDB instances for your deployment.
- The service or services that must connect to a specific instance.
-
Configure the MongoDB connection string or strings for your deployment. For
more information on how to format the connection strings, refer to the following
tables.
Table 17. Configuration Steps Based on Deployment Steps Deployment Type Configuration Steps Your deployment has one MongoDB instance. - Open the systemlink-secrets.yaml file.
- Set global.secrets.mongodb.connection_string with the value of the appropriate connection string.
Your deployment has multiple MongoDB instances. For each service in the Configuration Parameters for a MongoDB Instance table, configure the connection string.
- Open the systemlink-values.yaml file.
- Set <service_name>.mongodb.connection_string with the appropriate value for the MongoDB instance you want that service to connect with.
- Substitute <service_name> with the value from the Service column of the Configuration Parameters for a MongoDB Instance table.
For example, to configure the Alarm Service connection string, set the alarmservice.mongodb.connection_string value. For services that appear in the table more than once, such as userservices, only set the connection string once.
Note SystemLink replaces the placeholders in angle brackets such as <username>, <password>, and <database> dynamically when you deploy. You do not have to replace these placeholders manually. Type the string exactly as it appears unless noted otherwise.Table 18. Connection String based on MongoDB Type MongoDB Type Connection String MongoDB Atlas mongodb+srv://<username>:<password>@my-atlas-cluster.mongodb.net/<database> MongoDB Community mongodb://<username>:<password>@my-mongodb-cluster-0,my-mongodb-cluster-1,my-mongodb-cluster-2/<database>?replicaSet=rs0 MongoDB Community with one set of credentials mongodb://myusername:mypassword@my-mongodb-cluster-0,my-mongodb-cluster-1,my-mongodb-cluster-2/<database>?replicaSet=rs0 With the following stipulations:
- myusername is the username for your MongoDB instance.
- mypassword is the password for your MongoDB instance.
- Open systemlink-values.yaml.
- Configure globals.mongodb.install to false.
Choosing a MongoDB Deployment
Most of the SystemLink services use MongoDB as the primary database. You can use a MongoDB instance in the same Kubernetes cluster as your SystemLink Enterprise installation or an external instance. As of SystemLink Enterprise version 2023-10 services support the use of a single stand-along MongoDB instance.
| Deployment | When to Use | Details |
|---|---|---|
| MongoDB Atlas | You want to simplify database provisioning, operation, backup, and restore operations. | NI recommends using the following guidelines for your
deployment.
Note You can use Atlas features to initialize a smaller
instance and auto-scale as needed. Set limits to prevent
costs from scaling beyond your budget. |
| Standalone MongoDB instance such as MongoDB Enterprise Advanced | You want to control your database but require additional enterprise-level control. |
NI recommends using the following guidelines for your deployment.
|
| MongoDB in a Helm chart such as the Bitnami MongoDB chart |
|
You can run this instance on existing Kubernetes worker nodes or dedicated worker nodes using taints and tolerations. NI recommends using the following custom settings when
deploying. You can adjust the requests and limits to fit
with other pods on the Kubernetes worker
node.
resources:
requests:
cpu: 4
memory: 32Gi
limits:
memory: 32Gi
persistence:
enabled: true
accessModes:
- ReadWriteOnce
size: 512Gi
annotations: {} |
Related Information
- Components of a SystemLink Enterprise System
SystemLink Enterprise implements a server-client architecture to transmit data over a connected network between your systems and server. Use the minimum required SystemLink Enterprise system components as a starting point for building your system.
- SystemLink Enterprise GitHub Release Notes
- MongoDB Atlas
- MongoDB Bitnami
- MongoDB Enterprise Advanced