This documentation site is no longer maintained. For the latest Delphix product documentation, please visit help.delphix.com
Continuous Data

MongoDB link operations

dSource creation via CLI

To create a dSource and perform operations via CLI, login to the Delphix Continuous Data Engine using the admin user account.

ssh admin@<CONTINUOUS-DATA-FQDN-or-IP>

Set default linking parameters (common for all types of ingestions)

Run the commands below to set the default linking parameters. The below example uses testscfg source config.

database link
set type=LinkParameters
set linkData.type=AppDataStagedLinkData	
set name=testds
set group=Untitled
set linkData.config=testscfg
set linkData.environmentUser=demo-stg/delphix_os
set linkData.stagingEnvironment=demo-stg
set linkData.stagingEnvironmentUser=demo-stg/delphix_os
set linkData.syncParameters.parameters={\"resync\":true}

Run the commands below to link parameters for the seed ingestion type.

set linkData.parameters="{\"dsource_type_definition\":\"seed - [Replicaset(Empty Instance)]\",\"src_db_details\":[],\"staging_db_details\":[{\"replicaset_name\":\"myrs0\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"mount_path\":\"\/mnt\/provision\/seed_cli_stg\",\"bind_ip\":\"0.0.0.0\",\"start_portpool\":37701}],\"staging_tuning_details\":[],\"mongodump_config\":[],\"shard_details\":[],\"ops_backup_details\":[],\"enable_authentication\":true,\"staging_db_auth\":[{\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"cluster_auth_mode\":\"keyFile\",\"keyfile_path\":\"\/home\/delphix\/keyfile\/keyfile\"}],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"source_encrypted\":false,\"encryption_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}"

Run the commands below to link parameters for the offlinemongodump ingestion type.

set linkData.parameters="
{\"dsource_type_definition\":\"offlinemongodump - [Replicaset(Manual mongodump backups)]\",\"src_db_details\":[],\"staging_db_details\":[{\"replicaset_name\":\"myrs0\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"mount_path\":\"\/mnt\/provision\/test_stg\",\"bind_ip\":\"0.0.0.0\",\"start_portpool\":37520}],\"staging_tuning_details\":[],\"mongodump_config\":[{\"backup_metadata_file\":\"\/home\/delphix\/509_backup\/offlinedump\/bkp_metadata_file.txt\",\"backupfile\":\"\/home\/delphix\/509_backup\/offlinedump\/dlpx_cfgrs509\",\"enable_logsync\":false,\"mongodump_params\":[],\"mongorestore_params\":[]}],\"shard_details\":[],\"ops_backup_details\":[],\"enable_authentication\":true,\"staging_db_auth\":[{\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"cluster_auth_mode\":\"keyFile\",\"keyfile_path\":\"\/home\/delphix\/keyfile\/keyfile\"}],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"source_encrypted\":false,\"encryption_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}"

Run the commands below to link parameters for the onlinemongodump ingestion type.

set linkData.parameters="
{\"dsource_type_definition\":\"onlinemongodump - [Replicaset(Automated mongodump backups)]\",\"src_db_details\":[{\"host_conn_string\":\"demo-src.dcol1.delphix.com:30030\",\"db_user\":\"puneadmin\",\"db_password\":\"delphix\"}],\"staging_db_details\":[{\"replicaset_name\":\"myrs0\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"mount_path\":\"\/mnt\/provision\/test_stg\",\"bind_ip\":\"0.0.0.0\",\"start_portpool\":33702}],\"staging_tuning_details\":[],\"mongodump_config\":[],\"shard_details\":[],\"ops_backup_details\":[],\"enable_authentication\":true,\"staging_db_auth\":[{\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"cluster_auth_mode\":\"keyFile\",\"keyfile_path\":\"\/home\/delphix\/keyfile\/keyfile\"}],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"source_encrypted\":false,\"encryption_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}

Run the commands below to link parameters for the shardedsource ingestion type.

set linkData.parameters="
{\"client_tls_cacert\":\"\",\"client_tls_cert\":\"\",\"dsource_type_definition\":\"shardedsource - [Sharded(Ops Manager Backups)]\",\"enable_authentication\":true,\"enable_ldap\":false,\"enable_ssl_tls\":false,\"encryption_params\":[],\"ldap_params\":[],\"mongodump_config\":[],\"ops_backup_details\":[],\"shard_details\":[],\"source_encrypted\":false,\"src_db_details\":[],\"ssl_tls_params\":[],\"staging_db_auth\":[{\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"cluster_auth_mode\":\"keyFile\",\"keyfile_path\":\"\/home\/delphix\/keyfile\/keyfile\"}],\"staging_db_details\":[{\"bind_ip\":\"0.0.0.0\",\"mount_path\":\"\/mnt\/provision\/sharded_cli_stg\",\"replicaset_name\":\"myrs0\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"start_portpool\":28000}],\"staging_tuning_details\":[]\"d_source_type\":\"shardedsource\",\"src_mongo_host_conn\":\"\",\"src_replicaset_name\":\"\",\"src_db_user\":\"\",\"src_db_password\":\"\",\"enable_logsync\":false,\"mongo_host\":\"demo-stg.dcol1.delphix.com\",\"start_portpool\":28501,\"mongos_port\":28511,\"bind_ip\":\"0.0.0.0\",\"oplog_size\":1024,\"journal_interval\":30,\"storage_engine\":\"wiredTiger\",\"mount_path\":\"\/mnt\/provision\/sharded_stg\",\"backup_metadata_file\":\"\/home\/delphix\/509_backup\/sharded_mongo_bkpdate.txt\",\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"config_backupfile\":\"\/home\/delphix\/509_backup\/shardedbkp\/config-configRS.tar.gz\",\"shard_backupfiles\":[{\"backupfile\":\"\/home\/delphix\/509_backup\/shardedbkp\/myShard_0.tar.gz\"},{\"backupfile\":\"\/home\/delphix\/509_backup\/shardedbkp\/myShard_1.tar.gz\"},{\"backupfile\":\"\/home\/delphix\/509_backup\/shardedbkp\/myShard_2.tar.gz\"}],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_authentication\":true,\"keyfile_path\":\"\/home\/delphix\/509_backup\/shardedbkp\/keyfile\",\"cluster_auth_mode\":\"keyFile\",\"source_encrypted\":false,\"encryption_method\":\"KeyFile\",\"encryption_keyfile\":\"\",\"kmip_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"enable_auditlog\":false,\"auditlog_params\":[],\"enable_setparams\":false,\"setparam_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}"

Run the commands below to link parameters for the shardedsource ingestion type.

set linkData.parameters="
{\"dsource_type_definition\":\"shardedsource - [Sharded(Cluster-to-cluster Sync)]\",\"src_db_details\":[{\"host_conn_string\":\"mkk-punedb01.dcol1.delphix.com:52011\",\"db_user\":\"puneadmin\",\"db_password\":\"DELPHIX@123\"}],\"staging_db_details\":[{\"replicaset_name\":\"\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"mount_path\":\"\/mnt\/provision\/sharded_stg\",\"bind_ip\":\"0.0.0.0\",\"start_portpool\":46701}],\"staging_tuning_details\":[],\"mongodump_config\":[],\"shard_details\":[{\"mongos_port\":46801,\"mongosync_port\":46899}],\"ops_backup_details\":[],\"enable_authentication\":true,\"staging_db_auth\":[{\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"cluster_auth_mode\":\"keyFile\",\"keyfile_path\":\"\/home\/delphix\/keyfile\/keyfile\"}],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"source_encrypted\":false,\"encryption_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}"

Run the commands below to link parameters for the nonshardedsource ingestion type.

set linkData.parameters="{\"client_tls_cacert\":\"\",\"client_tls_cert\":\"\",\"dsource_type_definition\":\"nonshardedsource - [Replicaset(Ops Manager Backups)]\",\"enable_authentication\":true,\"enable_ldap\":false,\"enable_ssl_tls\":false,\"encryption_params\":[],\"ldap_params\":[],\"mongodump_config\":[],\"ops_backup_details\":[],\"shard_details\":[],\"source_encrypted\":false,\"src_db_details\":[],\"ssl_tls_params\":[],\"staging_db_auth\":[{\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"cluster_auth_mode\":\"keyFile\",\"keyfile_path\":\"\/path\/keyfile\"}],\"staging_db_details\":[{\"bind_ip\":\"0.0.0.0\",\"mount_path\":\"\/mnt\/provision\/test_stg\",\"replicaset_name\":\"myrs0\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"start_portpool\":28000}],\"staging_tuning_details\":[]\"d_source_type\":\"nonshardedsource\",\"src_mongo_host_conn\":\"\",\"src_replicaset_name\":\"\",\"src_db_user\":\"\",\"src_db_password\":\"\",\"enable_logsync\":false,\"mongo_host\":\"demo-stg.dcol1.delphix.com\",\"start_portpool\":28501,\"mongos_port\":28511,\"bind_ip\":\"0.0.0.0\",\"oplog_size\":1024,\"journal_interval\":30,\"storage_engine\":\"wiredTiger\",\"mount_path\":\"\/mnt\/provision\/test_stg\",\"backup_metadata_file\":\"\/path\/offline_mongo_bkpdate.txt\",\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"config_backupfile\":\"\/path\/Replicaset_backup.tar.gz\",\"shard_backupfiles\":[],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_authentication\":true,\"keyfile_path\":\"\/path\/keyfile\",\"cluster_auth_mode\":\"keyFile\",\"source_encrypted\":false,\"encryption_method\":\"KeyFile\",\"encryption_keyfile\":\"\",\"kmip_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"enable_auditlog\":false,\"auditlog_params\":[],\"enable_setparams\":false,\"setparam_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}"

Run the commands below to link parameters for the extendedsource ingestion type.

set linkData.parameters="{\"dsource_type_definition\":\"extendedcluster-[Replicaset(Addmembertoexistingcluster)]\",\"src_db_details\":[{\"host_conn_string\":\"mkk-punedb01.dcol1.delphix.com:51001\",\"db_user\":\"puneadmin\",\"db_password\":\"DELPHIX@123\"}],\"staging_db_details\":[{\"replicaset_name\":\"\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"mount_path\":\"\/mnt\/provision\/extended_stg\",\"bind_ip\":\"0.0.0.0\",\"start_portpool\":34568}],\"staging_tuning_details\":[],\"mongodump_config\":[],\"shard_details\":[],\"ops_backup_details\":[],\"enable_authentication\":true,\"staging_db_auth\":[{\"mongo_db_user\":\"dlpxadmin\",\"mongo_db_password\":\"delphix\",\"cluster_auth_mode\":\"keyFile\",\"keyfile_path\":\"\/home\/delphix\/keyfile\/keyfile\"}],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"source_encrypted\":false,\"encryption_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}"

Run the commands below to link parameters for the stagingpush ingestion type.

set linkData.parameters="{\"dsource_type_definition\":\"stagingpush-[Replicaset(EmptyvFiles)]\",\"src_db_details\":[{\"host_conn_string\":\"demo-stg.dcol1.delphix.com:51230\",\"db_user\":\"puneadmin\",\"db_password\":\"DELPHIX@123\"}],\"staging_db_details\":[{\"replicaset_name\":\"\",\"staging_host\":\"demo-stg.dcol1.delphix.com\",\"mount_path\":\"\/mnt\/provision\/stagingpush_stg\",\"bind_ip\":\"0.0.0.0\",\"start_portpool\":0}],\"staging_tuning_details\":[],\"mongodump_config\":[],\"shard_details\":[],\"ops_backup_details\":[],\"enable_authentication\":false,\"staging_db_auth\":[],\"enable_ssl_tls\":false,\"ssl_tls_params\":[],\"enable_ldap\":false,\"ldap_params\":[],\"source_encrypted\":false,\"encryption_params\":[],\"client_tls_cert\":\"\",\"client_tls_cacert\":\"\"}"

Commit

Run the command below to commit the change.

commit;

Disable

Run the command below to disable the dSource.

source
select testdb
disable
commit

Enable

Run the command below to enable the dSource.

source
select testdb
enable
commit