- Administer Ops Manager >
- Manage Snapshot Storage >
- Manage Oplog Storage
Manage Oplog Storage¶
Throughout the lifecycle of a backup, the Backup Agent tails the oplog of each replica set and sends new oplog entries to Ops Manager. The oplog entries are sent in compressed bundles of approximately 10 MB in size called oplog slices. These oplog slices are stored in one or more MongoDB databases called Oplog Stores. Every Ops Manager deployment needs at least one Oplog Store.
When you enable backups, you are prompted to create one Oplog Store. Once one Oplog Store is created, you manage it separately from your snapshot stores and can create additional Oplog Stores.
This tutorial covers creating additional Oplog Stores to store oplog entries. Like any MongoDB instance, Oplog Stores can exist on any host running MongoDB that the Ops Manager application can access.
Prerequisites¶
Before creating any Oplog Stores:
- Ensure storage volume(s) with sufficient capacity to store the oplog MongoDB database are attached to the Ops Manager or MongoDB host.
- Deploy the dedicated MongoDB instance(s) to host the Oplog Stores.
- Ensure the host running the Ops Manager Backup Daemon service has sufficient capacity to store the head database.
- Secure the instance that stores your Oplog Stores using authentication and SSL. Oplog Stores support all authentication mechanisms.
Add a Oplog Store¶
Click Create New Oplog Store.¶
Provide the Oplog Store details.¶
Field | Contents | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Name | A name for the Oplog Store | |||||||||||||||
Datastore Type | Select Standalone, Replica Set or Sharded Cluster. | |||||||||||||||
MongoDB Host List (replica set and sharded cluster only) | Type a comma-separated list of mongod instances
(for a Replica Set) or mongos instances (for a
Sharded Cluster) that comprise the Oplog Store database in
the Example
|
|||||||||||||||
MongoDB Hostname (Standalone only) | Type the hostname of the standalone MongoDB instance. | |||||||||||||||
MongoDB Port (Standalone only) | Type the port number of the standalone MongoDB instance. | |||||||||||||||
Username |
|
|||||||||||||||
Password (optional) |
|
|||||||||||||||
Connection Options (optional) | Type any additional configuration file options for the MongoDB instance. This field supports unescaped values only. For proper syntax, see Connection String URI Format in the MongoDB manual. |
|||||||||||||||
Encrypted Credentials (optional) | Select if the credentials for the database were encrypted using the credentialstool. The credentials include the Username, Password, AWS Access Key ID and AWS Secret Key. | |||||||||||||||
Use TLS/SSL (optional) | Select if the Oplog Store database only accepts connection encrypted using TLS. To enable TLS on the Oplog Store database, see Configure mongod and mongos for TLS/SSL. |
|||||||||||||||
New Assignment Enabled (optional) | Select if you want to enable this Oplog Store after creating it. This is selected by default so the Oplog Store can be assigned backup jobs. If you clear this checkbox, the Oplog Store is created but you cannot assign backups to this Oplog Store. |
Click Create.¶
Edit an Existing Oplog Store¶
Once created, Oplog Stores are listed directly on the Oplog Storage page in a table. Each row contains the settings for each Oplog Store.
Navigate to the Oplog Storage page.¶
- Click the Admin link.
- Click the Backup tab.
- (Optional) If you have not previously set the head directory, set it in the Head Directory box.
- Click the Oplog Storage page.
Go to the row for the Oplog Store you want to edit.¶
In the MongoDB Connection column, update any values that need to be changed in the following fields:¶
Field | Contents | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
<hostname>:<port> | Type in one or more hosts that comprise the Oplog Store
database in the Important If these hosts are changed, the Oplog Store database they host must have the same data as the original Oplog Store database. Changing the host to a new Oplog Store database results in data loss.
|
|||||||||||||||
MongoDB Auth Username |
|
|||||||||||||||
MongoDB Auth Password |
|
|||||||||||||||
Encrypted Credentials | Select if the credentials for the database were encrypted using the credentialstool. The credentials include the Username, Password, AWS Access Key ID and AWS Secret Key. | |||||||||||||||
Use TLS/SSL | Select if the Oplog Store database only accepts connection encrypted using TLS. To enable TLS on the Oplog Store database, see Configure mongod and mongos for TLS/SSL. |
|||||||||||||||
Connection Options | Type any additional configuration file options for the MongoDB instance. This field supports unescaped values only. | |||||||||||||||
Assignment Labels | Type a comma-separated list of labels to assign the Oplog Stores to specific groups. | |||||||||||||||
Write Concern | Select your preferred Write Concern:
|
Select the checkbox in the Assignment Enabled column.¶
Select if you want to enable this Oplog Store after creating it. This is selected by default so the Oplog Store can be assigned backup jobs. If you clear this checkbox, the Oplog Store is created but you cannot assign backups to this Oplog Store.
Click Save.¶
If you change any connection string values, restart all the Ops Manager instances including those running Backup Daemons.¶
Warning
Modifying the connection string values for an existing blockstore requires you to restart all Ops Manager components, including those only running the Backup Daemon to apply those changes. Connection parameters include:
- <hostname>:<port>,
- MongoDB Auth Username,
- MongoDB Auth Password,
- Encrypted Credentials,
- Use TLS/SSL, and
- Connection Options.
If you change to another Oplog Store host, the data on the existing Oplog Store is not copied automatically to the other Oplog Store.
See also
For more details on the MongoDB connection string uri, see Connection String URI Format in the MongoDB Manual.
Delete a Oplog Store¶
Navigate to the Oplog Storage page.¶
- Click the Admin link.
- Click the Backup tab.
- (Optional) If you have not previously set the head directory, set it in the Head Directory box.
- Click the Oplog Storage page.