0

I am trying to start MongoDB from the terminal. When I navigate to the folder and hit 'ls', all the applications show up but when I type in the name of the application( 'mongod'), it says it is not found!

Abes-MacBook-Air:bin abe$ ls

bsondump    mongodump   mongoimport mongorestore    mongostat
mongo       mongoexport mongooplog  mongos      mongotop
mongod      mongofiles  mongoperf   mongosniff

Abes-MacBook-Air:bin abe$ mongod

-bash: mongod: command not found

What is going on?

5

The executable is in your current working directory. Therefore you need to add ./ to your command. So try ./mongod.

See this UNIX StackExchange question for details and background: Why do we use “./” to execute a file?

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .