By checking  /var/log/mongodb/mongod.log, we can see the error message:


Detected unclean shutdown - /var/lib/mongo/mongod.lock is not empty.

The solution for this problem can be found at http://stackoverflow.com/questions/9884233/mongodb-service-is-not-starting-up

sudo rm /var/lib/mongodb/mongod.lock
mongod --repair
sudo service mongodb start

It solved the problem.

These commands might be also useful:

kill current mongod process:
1. Find pid

ps -ef | grep mongo

2. kill pid

kill -9 PID
Advertisements