0

I have collection-0-xxx.wt and index-0-xxx.wt files simply copied from another dbpath.

I am wondering if those files are enough to restore the data in MongoDB. If yes, how can I do that? If not, what other files are needed? Thanks!

  1. MongoDB Backup Methods
  2. How to restore .wt backup file to local MongoDB?
1
  • Short and simple: You need to copy all files from dbPath Dec 21, 2022 at 16:29

1 Answer 1

0

As one other user wrote, that you need to have whole content of dbPath -directory copied. This is called snapshot copy. You can't copy just "some of" those files, copy must include all, and all of those files must be from the same moment of time. This is f.ex. the easiest way to create (fast) secondary to replica set, which primary have huge amount of data.

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.