My machine (OSX) had a power failure and when restarted, I have one db in MongoDB that is completely unrecoverable. I am using the db per directory with dbpath and logpath specified options and was able to recover all except one of the dbs. This is the log from the unrecoverable one. Any ideas would be helpful - I have run --repair and removed the lock file with zero results.

The Error Log message in terminal:

2015-10-07T11:28:22.102+0530 W STORAGE  [initandlisten] database/Users/JineshJohn/TECSOL/zatsa2/data/db local could not be opened due to DBException 0: assertion src/mongo/db/storage/mmap_v1/extent.h:77 
2015-10-07T11:28:22.108+0530 I STORAGE  [initandlisten] exception in initAndListen: 0 assertion src/mongo/db/storage/mmap_v1/extent.h:77, terminating
2015-10-07T11:28:22.108+0530 I CONTROL  [initandlisten] now exiting
2015-10-07T11:28:22.108+0530 I NETWORK  [initandlisten] shutdown: going to close listening sockets...
2015-10-07T11:28:22.108+0530 I NETWORK  [initandlisten] removing socket file: /tmp/mongodb-27017.sock
2015-10-07T11:28:22.108+0530 I NETWORK  [initandlisten] shutdown: going to flush diaglog...
2015-10-07T11:28:22.108+0530 I NETWORK  [initandlisten] shutdown: going to close sockets...
2015-10-07T11:28:22.108+0530 I STORAGE  [initandlisten] shutdown: waiting for fs preallocator...
2015-10-07T11:28:22.108+0530 I STORAGE  [initandlisten] shutdown: final commit...
2015-10-07T11:28:22.108+0530 I JOURNAL  [initandlisten] journalCleanup...
2015-10-07T11:28:22.108+0530 I JOURNAL  [initandlisten] removeJournalFiles
2015-10-07T11:28:22.108+0530 I JOURNAL  [initandlisten] Terminating durability thread ...
2015-10-07T11:28:22.213+0530 I JOURNAL  [journal writer] Journal writer thread stopped
2015-10-07T11:28:22.213+0530 I JOURNAL  [durability] Durability thread stopped
2015-10-07T11:28:22.213+0530 I STORAGE  [initandlisten] shutdown: closing all files...
2015-10-07T11:28:22.214+0530 I STORAGE  [initandlisten] closeAllFiles() finished
2015-10-07T11:28:22.214+0530 I STORAGE  [initandlisten] shutdown: removing fs lock...
2015-10-07T11:28:22.214+0530 I CONTROL  [initandlisten] dbexit:  rc: 100
  • Do you have a backup?
    – Philᵀᴹ
    Oct 7, 2015 at 8:05
  • Or a replica set member to sync from? Oct 7, 2015 at 8:22
  • no i don't have a backup i want to solve this issue because now it is in development mode so data loss is not a problem
    – Nikhil Mk
    Oct 7, 2015 at 8:49

1 Answer 1


Try to use mongodump and mongorestore. mongodump works more forcefully then repair. Hope it will work and keep updated.

Your Answer

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

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