can't use mongorestore command to restore from a given path

Mahmoud Elsayed 1 Reputation point
2021-05-27T15:48:07.64+00:00

[root@dockermg-01 db01]# mongorestore --writeConcern {w:0} mongodb://mongodbtest01:somepassword@mongodbtest01.mongo.cosmos.azure.com:10255/?ssl=true&retrywrites=false&replicaSet=globaldb&maxIdleTimeMS=120000&appName=@mongodbtest01@ /Backup/mongodb/backups/mongodbtest01.mongo.cosmos.azure.com.db01.mongodb.20210523000709/db01/collection01.bson.gz
[1] 4644
[2] 4645
[3] 4646
[4] 4647
bash: /Backup/mongodb/backups/mongodbtest01.mongo.cosmos.azure.com.db01.mongodb.20210523000709/db01/collection01.bson.gz: cannot execute binary file: Exec format error
[2] Done retrywrites=false
[3]- Done replicaSet=globaldb
[4]+ Done maxIdleTimeMS=120000
[root@dockermg-01 db01]# 2021-05-27T14:36:49.595+0000 using default 'dump' directory
2021-05-27T14:36:49.596+0000 try 'mongorestore --help' for more information
2021-05-27T14:36:49.596+0000 Failed: mongorestore target 'dump' invalid: stat dump: no such file or directory

Azure Cosmos DB
Azure Cosmos DB
An Azure NoSQL database service for app development.
1,613 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.