- Agents >
- Automation Agent >
- Install or Update the Automation Agent >
- Install the Automation Agent on OS X
Install the Automation Agent on OS X¶
On this page
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.
Prerequisites¶
Server Networking Access¶
The hosts that serve the MongoDB deployments must:
Have full networking access to each other through their fully qualified domain names (FQDNs). Each host must be able to reach every other host through the FQDN.
To find the FQDN for each host:
On Linux / macOS hosts, run the following command in the shell:
On Windows hosts, run the following command in Powershell:
Resolve each FQDN to a unique IP address.
Run the following domain internet groper (
dig
) shell command to find the host’s IP address.Note
dig
is available for Microsoft Windows. Download and install the BIND tools from http://www.isc.org/downloads/Set the Common Name or Subject Alternative Name value of any SSL certificates to the MongoDB host’s FQDN.
The network configuration must allow each Automation Agent to make a direct connection to every MongoDB deployment listed on the Deployment page. Ops Manager does not support port forwarding.
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
andWrite
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.
Procedure¶
This section includes procedures for both installing and updating the Automation Agent.
Install the Automation Agent on OS X¶
Installation Tip for Binding the Agent to a Group
You can also access install instructions in Ops Manager, including commands you can copy and paste: click Deployment, then Agents, then Downloads & Settings.
Download the latest version of the Automation Agent archive.¶
From the Terminal, issue this command:
Install the Automation Agent.¶
To install the agent, extract the archive. For example:
The Automation Agent is installed.
Edit the local.config
file.¶
In the directory where you installed the Automation Agent, edit the
local.config
file to either:
Bind to a specific group via the
mmsGroupId
,mmsApiKey
, andmmsBaseUrl
settings.- or -
Add the server to a server pool via
serverPoolKey
,serverPoolPropertiesFile
,serverPoolStateFile
, andmmsBaseUrl
settings.
Configure for a Specific Group¶
Update the following configuration keys:
- For
mmsGroupId
, set to your GroupID. - For
mmsApiKey
, set to the group’s agent API key. - For
mmsBaseUrl
, set to the URL of the Ops Manager Application. Include the port number.
Do not configure the server pool settings:
serverPoolKey
, serverPoolPropertiesFile
,
serverPoolStateFile
.
Configure for a Server Pool¶
Update the following configuration keys:
For
mmsBaseUrl
, set to the URL of the Ops Manager Application. Include the port number.For
serverPoolKey
, set to the Server Pool Key.To find the server pool key, in the Admin menu, go to Server Pool view and click on the Agent Configuration tab.
For
serverPoolPropertiesFile
, set to the full filepath of a file that contains server properties. Ensure the Automation Agent can read the file.The properties file contains key/value pairs of the form
<property>=<value>
. The Ops Manager Administrator decides on both the property names and values.Note
Ensure that the properties file contains the desired property names and values before starting the Automation Agent on the server.
Once the server is registered with the pool, changes to the properties file do not take effect until the server is first removed and the Automation Agent restarted.
For
serverPoolStateFile
, set to the full filepath of the file to be used by the Automation Agent.Ensure that the directory path to the file exists and the agent has read and write access to the directory. The file itself need not exist; however, if it does exist, the agent must have read and write access to the file.
Do not configure the group settings:
mmsGroupId
and mmsApiKey
.
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
<install-directory>/local.config
file, set the httpProxy
value to the URL of to
your proxy server:
Create the automation and data directories.¶
Create the directories for the Automation Agent:
Component | Default Directory |
---|---|
Automation Agent binaries | /var/lib/mongodb-mms-automation |
Automation Agent logs | /var/log/mongodb-mms-automation |
MongoDB databases created by the Automation Agent | /data |
The system user that runs the Automation Agent should own these directories.
Using a Different Path than /var/lib
By default, the Automation Agent binaries and Ops Manager
configuration backup file are located in /var/lib/mongodb-mms-
automation
. If you want to store these files in a different
directory, follow these procedures:
To change the location of the Automation Agent Binaries:
Click Deployment; Agents; and then Downloads & Settings.
Below the Download Directory heading, click the pencil icon to the right of the path shown in Download Directory (Linux/MacOS).
Change the path to the new path you want.
Click Save.
Create the new directory you specified on each host that runs an Automation Agent.
Important
Make sure the system user that runs the Automation Agent can write to this new directory.
To change the location of the Automation Agent configuration backup:
Open the Automation Agent configuration file in your preferred text editor.
Change the
mmsConfigBackup
setting to the new path for the configuration backup file.Save the Automation Agent configuration file.
Move the configuration backup file to the new directory.
Start the Automation Agent.¶
Issue the following command:
Update the Automation Agent on OS X¶
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.
Stop any currently running Automation Agents.¶
Issue the following command:
Download the latest version of the Automation Agent archive.¶
From the Terminal, issue this command:
Install the Automation Agent.¶
To install the agent, extract the archive. For example:
The Automation Agent is installed.
Edit the local.config
file.¶
In the directory where you installed the Automation Agent, edit the
local.config
file to either:
Bind to a specific group via the
mmsGroupId
,mmsApiKey
, andmmsBaseUrl
settings.- or -
Add the server to a server pool via
serverPoolKey
,serverPoolPropertiesFile
,serverPoolStateFile
, andmmsBaseUrl
settings.
Configure for a Specific Group¶
Update the following configuration keys:
- For
mmsGroupId
, set to your GroupID. - For
mmsApiKey
, set to the group’s agent API key. - For
mmsBaseUrl
, set to the URL of the Ops Manager Application. Include the port number.
Do not configure the server pool settings:
serverPoolKey
, serverPoolPropertiesFile
,
serverPoolStateFile
.
Configure for a Server Pool¶
Update the following configuration keys:
For
mmsBaseUrl
, set to the URL of the Ops Manager Application. Include the port number.For
serverPoolKey
, set to the Server Pool Key.To find the server pool key, in the Admin menu, go to Server Pool view and click on the Agent Configuration tab.
For
serverPoolPropertiesFile
, set to the full filepath of a file that contains server properties. Ensure the Automation Agent can read the file.The properties file contains key/value pairs of the form
<property>=<value>
. The Ops Manager Administrator decides on both the property names and values.Note
Ensure that the properties file contains the desired property names and values before starting the Automation Agent on the server.
Once the server is registered with the pool, changes to the properties file do not take effect until the server is first removed and the Automation Agent restarted.
For
serverPoolStateFile
, set to the full filepath of the file to be used by the Automation Agent.Ensure that the directory path to the file exists and the agent has read and write access to the directory. The file itself need not exist; however, if it does exist, the agent must have read and write access to the file.
Do not configure the group settings:
mmsGroupId
and mmsApiKey
.
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
<install-directory>/local.config
file, set the httpProxy
value to the URL of to
your proxy server:
Create the automation and data directories.¶
Create the directories for the Automation Agent:
Component | Default Directory |
---|---|
Automation Agent binaries | /var/lib/mongodb-mms-automation |
Automation Agent logs | /var/log/mongodb-mms-automation |
MongoDB databases created by the Automation Agent | /data |
The system user that runs the Automation Agent should own these directories.
Using a Different Path than /var/lib
By default, the Automation Agent binaries and Ops Manager
configuration backup file are located in /var/lib/mongodb-mms-
automation
. If you want to store these files in a different
directory, follow these procedures:
To change the location of the Automation Agent Binaries:
Click Deployment; Agents; and then Downloads & Settings.
Below the Download Directory heading, click the pencil icon to the right of the path shown in Download Directory (Linux/MacOS).
Change the path to the new path you want.
Click Save.
Create the new directory you specified on each host that runs an Automation Agent.
Important
Make sure the system user that runs the Automation Agent can write to this new directory.
To change the location of the Automation Agent configuration backup:
Open the Automation Agent configuration file in your preferred text editor.
Change the
mmsConfigBackup
setting to the new path for the configuration backup file.Save the Automation Agent configuration file.
Move the configuration backup file to the new directory.
Start the Automation Agent.¶
Issue the following command: