Mongodb won't start

Hi guys. i am trying to learn some new things. i am starting with ’ Get set for our back end development projects. and there was a challange to :

In your terminal, start MongoDB by entering:

mongod --smallfiles

in cloud9, everytime i write mongo --smallfiles it won’t start it says

munkiuke:~/workspace (master) $ mongod --smallfiles
bash: mongod: command not found

how can i make it work so i can continue.

I can’t remember exactly but try typing mongd in quotes so:

“mongod” --smallfiles

I think I found something close to that that worked.

didn’t work sadly. i tried, and i remade the new challange from scratch nope.

Ah try this one:

“mongod” --smallfiles --nojournal

I think this is the thread that solved it for me

1 Like

Enter this into the console:

:$ which mongodb

If that comes up with nothing, then mongodb didn’t get installed. You’ll have to install it.

:$ sudo apt-get install mongodb

I type: ./mongod --smallfiles

If you want mongodb on c9 take a look at this https://community.c9.io/t/setting-up-mongodb/1717

Yep, I hit the same problem.

mongod --port 27017 --dbpath=./data --smallfiles

worked for me.