I have a local mongo app on my MacBook I’ve been using for the last year which suddenly stopped working yesterday with the following output:
gene$ meteor [[[[[ ~/Dashboard ]]]]] => Started proxy. Unexpected mongo exit code 100. Restarting. Unexpected mongo exit code 100. Restarting. Unexpected mongo exit code 100. Restarting. Can't start Mongo server. MongoDB had an unspecified uncaught exception. This can be caused by MongoDB being unable to write to a local database. Check that you have permissions to write to .meteor/local. MongoDB does not support filesystems like NFS that do not allow file locking.
I have seen the other questions similar to this one on this forum and StackOverflow but none of the solutions worked for me.
- I removed the lock:
- changed permissions:
chown -R gene .meteor/local
- ran meteor as superuser
sudo meteor --allow-superuser
I cannot use
meteor reset because I need the db. Building a fresh version of the app works so I know the app code itself is not the problem. But I need to get the db back.
I’m not sure what caused this but I think it may possibly have something to do with some corruption I had from trying to back up my DB with dropbox. At some point the backup might have been interrupted and I had multiple copies of the same files from Dropbox, and I deleted the duplicates. Notably all of the files in
-rw-r--r--@ permission (with the @) rather than
-rw-r--r-- as they do on a fresh install, which seems suspicious. I suspect possibly WiredTiger is the problem but I don’t know how to repair/rebuild it without erasing the db.
At this point, all I really want to do is rescue the database. I wouldn’t even mind rebuilding a new version of the app manually, as long as I can retrieve all the text from my collections. But I can’t open a mongo shell to view the database because it has to launch meteor first and it can’t.
If anyone knows how I may fix the app without reset, or failing that, get a dump of all the collections in raw text so I can rebuild them in a fresh version of the app, please let me know what you suggest. Thanks!!