'MongoDB - mongodump - Error Could not parse catalog entry while replying to listIndexes
I migrated MongoDB from 3.2 to 5.0.2 step b step. I am trying to take mongodump.
For this I used the following command:
mongodump --db testdb --authenticationDatabase admin --username test123 --password pwd123 --out /var/backups/mongobackups/`date +"%m-%d-%y"`
I am getting the following error.
Failed: error dumping metadata: (Location5254501) Could not parse catalog entry while replying to listIndexes
Please help us on this to resolve.
Solution 1:[1]
In case someone is stuck with this error after updating MongoDB, the error is caused by bad indexes in the database. If you run db.XXX.validate() on each collection (where XXX is the name of the collection) it should tell which ones have problems. The validate command also instructs how to fix them. If nothing else works, you can delete and recreate the invalid indexes.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Guy Incognito |
