Skip to content
Open
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 15 additions & 3 deletions docs/deployment.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,22 @@
# Supported MongoDB deployments

* Percona Link for MongoDB supports only Replica Set to Replica Set synchronization. The source and target replica sets can have different number of nodes.
{{pcsm.full_name}} supports the following deployment topologies:

* **Replica Set to Replica Set**: The source and target replica sets can have different numbers of nodes.
* **Sharded cluster to Sharded cluster**: The source and target sharded clusters can have different numbers of shards. This functionality is in tech preview stage. See [Sharding support in {{pcsm.full_name}}](sharding.md) for details.

## Version requirements

* You can synchronize Percona Server for MongoDB or MongoDB Community/Enterprise Advanced/Atlas within the same major versions - 6.0 to 6.0, 7.0 to 7.0, 8.0 to 8.0
* Percona Link for MongoDB is supported on both ARM64 and x86_64 architectures.
* Minimal supported MongoDB versions are: 6.0.17, 7.0.13, 8.0.0
* You can connect the following MongoDB deployments:

## Supported architectures

* {{pcsm.full_name}} is supported on both ARM64 and x86_64 architectures.

## Supported MongoDB deployments

You can connect the following MongoDB deployments:

| Source | Target |
| --- | --- |
Expand Down
21 changes: 17 additions & 4 deletions docs/install/authentication.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,23 @@ When you [install PLM from repositories](repos.md), the environment file is crea

### Example environment file

```{.text .no-copy}
PLM_SOURCE_URI="mongodb://source:mys3cretpAssword@mysource1:27017,mysource2:27017,mysource3:27017/"
PLM_TARGET_URI="mongodb://target:tops3cr3t@mytarget1:27017,mytarget2:27017,mytarget3:27017/"
```
=== "Replica sets"

List all replica set members of the source and target clusters in the respective MongoDB connection string URIs to ensure {{pcsm.short}} can reach each of them:

```{.text .no-copy}
PLM_SOURCE_URI="mongodb://source:mys3cretpAssword@mysource1:27017,mysource2:27017,mysource3:27017/"
PLM_TARGET_URI="mongodb://target:tops3cr3t@mytarget1:27017,mytarget2:27017,mytarget3:27017/"
```

=== "Sharded clusters"

{{pcsm.short}} communicates with the clusters via `mongos`. Therefore, specify the hostname and port of the `mongos` instances of the source and target clusters in the respective MongoDB connection string URIs.

```{.text .no-copy}
PCSM_SOURCE_URI="mongodb://source-user:password@mongos-source1:27017/admin"
PCSM_TARGET_URI="mongodb://target-user:password@mongos-target1:27017/admin"
```

### Passwords with special characters

Expand Down
24 changes: 14 additions & 10 deletions docs/install/usage.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,22 @@
# Use {{plm.full_name}}
# Use {{pcsm.full_name}}

{{plm.full_name}} doesn't automatically start data replication after the startup. It has the `idle` status indicating that it is ready to accept requests.
{{pcsm.full_name}} doesn't automatically start data replication after startup. It has the `idle` status indicating that it is ready to accept requests.

You can interact with {{plm.full_name}} using the command-line interface or via the HTTP API. Read more about [PLM API](../api.md).
!!! tip "Understanding the workflow"

For an overview of how {{pcsm.short}} works and the replication workflow stages, see [How {{pcsm.full_name}} works](../intro.md).

You can interact with {{pcsm.full_name}} using the command-line interface or via the HTTP API. Read more about [{{pcsm.short}} HTTP API](../api.md).

## Before you start

Your target MongoDB cluster may be empty or contain data. PLM replicates data from the source to the target but doesn't manage the target's data. If the target already has the same data as the source, PLM overwrites it. However, if the target contains different data, PLM doesn't delete it during replication. This leads to inconsistencies between the source and target. To ensure consistency, manually delete any existing data from the target before starting replication.
Your target MongoDB cluster may be empty or contain data. {{pcsm.short}} replicates data from the source to the target but doesn't manage the target's data. If the target already has the same data as the source, {{pcsm.short}} overwrites it. However, if the target contains different data, {{pcsm.short}} doesn't delete it during replication. This leads to inconsistencies between the source and target. To ensure consistency, manually delete any existing data from the target before starting replication.

## Start the replication

Start the replication process between source and target clusters. PLM starts copying the data from the source to the target. First it does the initial sync by cloning the data and then applying all the changes that happened since the clone start.
Start the replication process between source and target clusters. {{pcsm.short}} starts copying the data from the source to the target. First it does the initial sync by cloning the data and then applying all the changes that happened since the clone start.

Then it uses the [change streams :octicons-link-external-16:](https://www.mongodb.com/docs/manual/changeStreams/) to track the changes to your data on the source and replicate them to the target.
Then it uses [change streams :octicons-link-external-16:](https://www.mongodb.com/docs/manual/changeStreams/) to track changes on the source and replicate them to the target.

=== "Command line"

Expand Down Expand Up @@ -72,7 +76,7 @@ To include or exclude a specific database and all collections it includes, pass

## Pause the replication

You can pause the replication at any moment. PLM stops the replication, saves the timestamp and enters the `paused` state. PLM uses the saved timestamp after you [resume the replication](#resume-the-replication).
You can pause the replication at any moment. {{pcsm.short}} stops the replication, saves the timestamp, and enters the `paused` state. {{pcsm.short}} uses the saved timestamp after you [resume the replication](#resume-the-replication).

=== "Command line"

Expand All @@ -90,7 +94,7 @@ You can pause the replication at any moment. PLM stops the replication, saves th

## Resume the replication

Resume the replication. PLM changes the state to `running` and copies the changes that occurred to the data from the timestamp it saved when you paused the replication. Then it continues monitoring the data changes and replicating them real-time.
Resume the replication. {{pcsm.short}} changes the state to `running` and copies the changes that occurred from the timestamp it saved when you paused the replication. Then it continues monitoring data changes and replicating them in real time.

=== "Command line"

Expand Down Expand Up @@ -143,9 +147,9 @@ Check the current status of the replication process.
$ curl http://localhost:2242/status
```

# Finalize the replication
## Finalize the replication

When you no longer need / want to replicate data, finalize the replication. PLM stops replication, creates the required indexes on the target, and stops. This is a one-time operation. You cannot restart the replicaton after you finalized it. If you run the `start` command, PLM will start the replication anew, with the initial sync.
When you no longer need to replicate data, finalize the replication. {{pcsm.short}} stops replication, creates the required indexes on the target, and stops. This is a one-time operation. You cannot restart the replication after you finalized it. If you run the `start` command, {{pcsm.short}} will start the replication anew, with the initial sync.

=== "Command line"

Expand Down
Loading