I am using mongodb-v1.8.1. Unfortunately my server gets hanged and i restarted my server.Once it comes back i could-not start the MongoDB. I removed the mongo.lock file and ran repair database query.Now mongo working fine. I am baffled with the mongo.lock file.What is the use of the mongo.lock file?.Removing the mongo.lock file will affect my existing data? Please let me know your suggestion..
Thanks,
mongod --dbpath /data/db --repair
from: docs.mongodb.com/manual/tutorial/… – Hyderabad