Skip to content

Instantly share code, notes, and snippets.

@dominicsayers
Created April 16, 2013 09:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dominicsayers/5394661 to your computer and use it in GitHub Desktop.
Save dominicsayers/5394661 to your computer and use it in GitHub Desktop.
Recover Mongodb on Ubuntu after an unclean shutdown
sudo -u mongodb rm /var/lib/mongodb/mongod.lock
sudo -u mongodb mongod --dbpath /var/lib/mongodb --repair
sudo start mongodb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment