Start Percona ClusterSync for MongoDB¶
Start Percona ClusterSync for MongoDB.
We recommend to use the packaged service scripts to run pcsm.
$ sudo systemctl start pcsm
Check the status with this command:
$ sudo systemctl status pcsm
You can start PCSM manually. This option is the way you start Percona ClusterSync for MongoDB if you installed it from source code
Run Percona ClusterSync for MongoDB with the following command if you haven’t defined MongoDB connection string URI before:
$ nohup pcsm --source <source-mongodb-uri> --target <target-mongodb-uri> --no-color > percona-clustersync-mongodb.log 2>&1 &
Alternatively, you can use environment variables:
$ export SOURCE_URI=<source-mongodb-uri>
$ export TARGET_URI=<target-mongodb-uri>
$ nohup pcsm --no-color > percona-clustersync-mongodb.log 2>&1 &
See Percona ClusterSync for MongoDB startup configuration for all available options.
How to see Percona ClusterSync for MongoDB logs¶
With the packaged systemd service, the log output to stdout is captured by
systemd’s default redirection to systemd-journald. You can view it with this
command:
$ sudo journalctl -u pcsm.service
See man journalctl for useful options such as --lines, --follow, etc.
If you started pcsm manually, see the file you redirected stdout and stderr to.
Next steps¶
Congratulations! you have successfully installed and connected PCSM to your source and target MongoDB. Now you have it up and running and you are ready to use it.
Use Percona ClusterSync for MongoDB
Created: January 13, 2026