Navigation
This version of the documentation is archived and no longer supported. To learn how to upgrade your version of MongoDB Ops Manager, refer to the upgrade documentation.
You were redirected from a different version of the documentation. Click here to go back.

Install the Automation Agent with rpm Packages

Overview

Ops Manager Automation relies on an Automation Agent, which must be installed on every server that runs a monitored MongoDB deployment. The Automation Agents periodically poll Ops Manager to determine the goal configuration, deploy changes as needed, and report deployment status back to Ops Manager.

Automation Agents can run only on 64-bit architectures.

Use this procedure to install the agent on RHEL, CentOS, SUSE, Amazon Linux, and other systems that use rpm packages.

If you are installing to a server that has an existing MongoDB deployment that was not installed with the rpm package, then instead install the agent using an archive and ensure the agent runs as the same user as the MongoDB process.

Prerequisites

Server Networking Access

The servers that host the MongoDB processes must have full networking access to each other through their fully qualified domain names (FQDNs). You can view a server’s FQDN by issuing hostname -f in a shell connected to the server. Each server must be able to reach every other server through the FQDN.

Ensure that your network configuration allows each Automation Agent to connect to every MongoDB process listed on the Deployment tab. Ensure that the network and security systems, including all interfaces and firewalls, allow these connections.

Installing to a Server that Already Runs MongoDB

If you install the Automation Agent to a server that is already running a MongoDB process, the agent must have:

  • Permission to stop the MongoDB process. The Automation Agent will restart the process using the agent’s own set of MongoDB binaries. If you had installed MongoDB with a package manager, use the same package manager to install the Automation Agent. This gives the agent the same owner as MongoDB.
  • Read and Write permissions on the MongoDB data directory and log directory.
  • Permission to stop, start, and update any existing Monitoring and Backup Agents.

Installing to a Server Before Installing MongoDB

If you deploy the Automation Agent to a server that does not have MongoDB installed, ensure the user that owns the Automation Agent has Read and Write permissions on the MongoDB data and log directories you plan to use.

Procedures

This section includes procedures for both installing and updating the Automation Agent.

Install the Automation Agent with an rpm Package

1

Download the latest version of the Automation Agent archive.

On a system shell, issue a command that resembles the following. Replace amd64 with your platform, as needed:

curl -OL <OpsManagerCentralURL>/download/agent/automation/mongodb-mms-automation-agent-manager-latest.x86_64.rpm
2

Install the Automation Agent Package

sudo rpm -U mongodb-mms-automation-agent-manager-latest.x86_64.rpm
3

Edit the automation-agent.config file.

Edit the automation-agent.config file.

sudo vi /etc/mongodb-mms/automation-agent.config

For mmsGroupId, enter your GroupID as the value. For mmsApiKey, enter the group’s agent API key.

mmsGroupId=<Group ID>
mmsApiKey=<agent API key>

For mmsBaseUrl, enter the URL of the Ops Manager Application. Include the port number.

mmsBaseUrl=<application URL>

For SUSE 11+ deployments only, configure the sslTrustedMMSServerCertificate setting. All other users should omit this step.

sslTrustedMMSServerCertificate=/etc/ssl/certs/UTN_USERFirst_Hardware_Root_CA.pem
4

Optional: Configure the Automation Agent to use a proxy server.

To configure the agent to connect to Ops Manager via a proxy server, you must specify the server in the httpProxy environment variable. In the /etc/mongodb-mms/automation-agent.config file, set the httpProxy value to the URL of to your proxy server:

httpProxy="http://proxy.example.com:9000"
5

Prepare the data directory.

The data directory stores MongoDB data and must be owned by the `mongod` user. For an existing MongoDB deployment, ensure the directory has the mongod user as owner. If no MongoDB deployment exists, create the directory and set the owner.

The following commands create a data directory and set the owner as the mongod user:

sudo mkdir /data
sudo chown mongod:mongod /data
6

Start the Automation Agent.

Issue the following command:

sudo service mongodb-mms-automation-agent start

Update the Automation Agent with an rpm Package

Important

The preferred way to update the Automation Agent is through the Ops Manager UI. If an Automation Agent is out of date, Ops Manager displays a warning on the Deployment page and provides a link to perform the update automatically.

If you use this procedure, you do not need to stop the agent. The update package automatically stops, unpacks, and then restarts the agent.

1

Download the latest version of the Automation Agent archive.

On a system shell, issue a command that resembles the following. Replace amd64 with your platform, as needed:

curl -OL <OpsManagerCentralURL>/download/agent/automation/mongodb-mms-automation-agent-manager-latest.x86_64.rpm
2

Install the Automation Agent Package

sudo rpm -U mongodb-mms-automation-agent-manager-latest.x86_64.rpm
3

Prepare the data directory.

The data directory stores MongoDB data and must be owned by the `mongod` user. For an existing MongoDB deployment, ensure the directory has the mongod user as owner. If no MongoDB deployment exists, create the directory and set the owner.

The following commands create a data directory and set the owner as the mongod user:

sudo mkdir /data
sudo chown mongod:mongod /data