Mongorestore Documentdb Best [ Free ]
Before running mongorestore , ensure your environment is configured for a successful connection:
Because DocumentDB requires TLS/SSL connections, you must always include --ssl . The --sslAllowInvalidHostnames flag is often necessary due to the way DocumentDB’s routing endpoint presents certificates.
Troubleshoot issues with mongorestore in Amazon DocumentDB | AWS re:Post mongorestore documentdb
Before running the restore command, ensure you have the following:
mongorestore --ssl \ --host="your-cluster.node.us-east-1.docdb.amazonaws.com:27017" \ --username=yourUser \ --password=yourPassword \ --sslCAFile global-bundle.pem \ /path/to/dump/directory Use code with caution. Before running mongorestore , ensure your environment is
The syntax for mongorestore against DocumentDB is identical to that for MongoDB:
DocumentDB’s write throughput is governed by instance size (e.g., R4, R5, T3). To avoid overwhelming the cluster: The syntax for mongorestore against DocumentDB is identical
mongorestore --host ... --gzip --db mydb /dump/gzipped/
mongorestore --host <documentdb-cluster-endpoint> \ --port 27017 \ --username <username> \ --password <password> \ --authenticationDatabase admin \ --ssl \ --sslAllowInvalidHostnames \ --db target_db \ /path/to/backup/dump