I read the docs I could find on the web but still I don't see what I am doing wrong.
I also saw there're 2-3 similar questions here on SO but not quite the same.
I tried both methods of starting it up but none of them works, it seems.
root@test02:~# service mongod start mongod start/running, process 1135 root@test02:~# /etc/init.d/mongod Usage: /etc/init.d/mongod COMMAND root@test02:~# /etc/init.d/mongod start Rather than invoking init scripts through /etc/init.d, use the service(8) utility, e.g. service mongod start Since the script you are attempting to invoke has been converted to an Upstart job, you may also use the start(8) utility, e.g. start mongod mongod start/running, process 1154 root@test02:~# ps aux | grep mongo root 1157 0.0 0.1 9392 896 pts/0 S+ 19:04 0:00 grep --color=auto mongo root@test02:~# So... nothing happens, no log files are created too.
1) What am I missing here?!
2) When I run it this way (through both ways),
will it know to use the /etc/mongod.conf file?
These are the relevant files which I have for MongoDB.
/etc/init.d/mongod /etc/mongod.conf /root/.mongorc.js /var/log/mongodb/mongod.log The last one does not exist in fact, though it should be there, I think.
/var/log/mongodb/mongod.log. Take a look inside there and see what it's complaining about. I remember needing to create a data directory for the service to store its files at before./data/dbdirectory, it seems its the default location. If that doesn't work, I don't know what to tell you.