I accidentally deleted 2 data (mydb.47, mydb.62) files from my /data/db of my mongodb. I have rest of the files in place...

Now my mongodb won't start up..I tried repairing it using this command

sudo -u mongod  mongod  --dbpath /data/db-new --repair --repairpath /data/db

Repair finished with no errors. Mongo docs say

You may also wish to move the repaired files to the old database location or update the dbPath to indicate the new location

I copied the files from /data/db-new to /data/db and started mongo server. But it is not starting...

Is there any way I could reclaim my data?

1 Answer 1


As per my knowledge you cannot reclaim your data using MONGO. But you can go for some other third party tools that can help to recover data from your hard disk.

I hope this link will help linux data recover on unix.stackexchange.com

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.