Setting up dedicated nodes for your MongoDB deployment

You can dedicate one or more worker nodes to MongoDBOps Manager. The nodes are then used exclusively by Ops Manager containers or pods.

About this task

You dedicate a node by adding a taint to the node. MongoDB Ops Manager then adds a corresponding toleration to the pods that use it exclusively. A node taint lets you mark a node so that the scheduler avoids using it for certain pods. The pods with the tolerations are then allowed to use the dedicated nodes and any other nodes in the cluster.

To make sure that your pods use those dedicated nodes, you can add a label that matches the taint to the same set of nodes. MongoDB Ops Manager also adds a node affinity to require that the pods can only schedule onto the labeled nodes.

Procedure

Repeat the following steps on each worker node that you plan to dedicate to the database deployment.

  1. Retrieve the name of the worker node that you want to dedicate to MongoDB Ops Manager.
    oc get nodes
  2. Taint the node with the NoSchedule effect for MongoDB Ops Manager.
    oc adm taint node <node_name> icp4data=opsmanager-mongodb:NoSchedule
  3. Label the node.
    oc label node <node_name> icp4data=opsmanager-mongodb
  4. Optional: Drain the node to safely evict all pods and ensure exclusiveness. If the node is newly added, this step is not required:
    oc adm drain <node_name> --ignore-daemonsets --delete-local-data
  5. Enable dedicated deployment during MongoDBOps Manager instance creation.
    Using the web console:
    Select Deploy on dedicated nodes on the Ops Manager configuration page and database configuration page.
    Using a custom resource:
    Set the dedicated key under the spec key to true in the Ops Manager custom resource.